Giter VIP home page Giter VIP logo

Comments (15)

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
Second the defect.

Using XP Media Center Edition 2002 with latest patches and SP3.

Original comment by [email protected] on 22 May 2009 at 7:02

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
Yeah, I am aware about that. This is due to windows service support: Mongoose 
calls
some Service Control Manager functions that are slow. Without that, startup is 
instant.

I will take a look.

Original comment by valenok on 22 May 2009 at 7:06

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024

Original comment by valenok on 22 May 2009 at 9:18

  • Changed state: Accepted

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
Okay, but note that I am not using the Windows Service version of Mongoose but 
rather
just the standalone file mongoose-2.6.exe. It should not be making any calls to 
the
Service Manager.

Original comment by [email protected] on 22 May 2009 at 11:11

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
I have removed all service related code from Mongoose, and will use separate
executable, srvany (part of Microsoft Resource Kit) as service launcher.

Submitted change http://code.google.com/p/mongoose/source/detail?r=378
Now, Mongoose starts instantly.
You would need to either wait for release 2.7 or sync to trunk and build 
yourself.

Original comment by valenok on 22 May 2009 at 8:57

  • Changed state: Fixed

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
From what I remember, srvany.exe was a not a redistributable file.

Original comment by [email protected] on 23 May 2009 at 4:37

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
I was unable to recreate this issue on XP Home or Vista Home Premium.  The 
first time
I ran there was a very short delay (<1 sec), and subsequent times there was no 
delay.

Original comment by [email protected] on 23 May 2009 at 5:05

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
The root of the problem was StartServiceCtrlDispatcher() function. Mongoose 
called it
at startup. If mongoose.exe was run by Windows Service Control Manager (SCM), 
that
function did block until service was stopped. If mongoose.exe was run by user, 
that
function return.
For some reason, StartServiceCtrlDispatcher() sometimes takes long time to 
return if
mongoose.exe was started by user, and sometimes it is almost instant. I am 
unable to
tell why. 

Original comment by valenok on 23 May 2009 at 7:10

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
About srvany.exe, how can I confirm that? I am not a lawyer.
If this is really the case, I will need to write my own version of it.

Original comment by valenok on 23 May 2009 at 7:13

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
Normally a program that can run as both a service and a console application 
will have
a command line parameter to indicate which mode to run.  It would not be too 
hard to
have a command line parameter of "-service" that would indicate to interface 
with the
Service Control Manager.  The installer could also be modified to include the
necessary command line.

Original comment by [email protected] on 23 May 2009 at 7:45

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
I do not know how to tell SCM to supply -service argument when it starts 
mongoose.

Original comment by valenok on 23 May 2009 at 7:50

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
The program can have another command line option to install itself as a service 
by
calling CreateService.  The command line to the service can be specified as 
part of
the path.  Be sure to put double quotes around the executable path (especially 
if it
will contain spaces.)  The sc command may also specify parameters in the 
binpath by
using double quotes, but it may not be able to put quotes around the executable 
name
possible causing the wrong exe to be launched.  Without quotes around the 
executable
path the OS might think that you wish to run 'C:\Program.exe' with the command 
line
of 'Files\Mongoose\Mongoose.exe -service'.

Original comment by [email protected] on 23 May 2009 at 8:36

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
If all Windows users have the SC command installed, it can detect whether 
Mongoose
has been installed and is running as a service. Then you would not need a 
command
option to inform Mongoose whether it is server-based or standalone.

By the way, thanks for being so responsive to user comments. You are a great
developer and your product is wonderful.

Original comment by [email protected] on 23 May 2009 at 1:15

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
Cool, thanks for the ideas, I will experiment to find what fits best.
Currently, I like external launcher idea more, since it keeps the server free of
service specific code and dependencies.

Original comment by valenok on 23 May 2009 at 5:30

from mongoose.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 19, 2024
I agree.

Original comment by [email protected] on 23 May 2009 at 5:40

from mongoose.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.