|
From: Marc T. <MT...@bl...> - 2007-08-30 15:37:19
|
Leif, Many thanks for your answers. I was a bit confused with the WrapperManager.sendServiceControlCode() method, mainly because the documentation says "If the service was not currently running then the control code will not be sent.". I wrongly interpreted "running" as "started" instead of "installed". I realize now, that it is very easy to start/stop and query the status of an installed service with this method. Best regards, Marc -----Original Message----- Message: 2 Date: Tue, 28 Aug 2007 14:07:20 +0900 From: Leif Mortenson <le...@ta...> Subject: Re: [Wrapper-user] Monitoring services from a Java application To: wra...@li... Message-ID: <46D...@ta...> Content-Type: text/plain; charset=3DISO-8859-1; format=3Dflowed Marc, If they are services, you could do this from the Wrapper using the WrapperManager.listServices(), or if you know a specific service you can use the WrapperManager.sendServiceControlCode() method. Pass in the SERVICE_CONTROL_CODE_INTERROGATE controlCode to find out what its latest state is. See the javadocs here: http://wrapper.tanukisoftware.org/doc/english/javadocs.html Cheers, Leif Marc Tibout wrote: > > Hi, > > I have a Java application that requires a number of services to be up=20 > and running. > > The application target platform is Windows and the services are=20 > installed/started/stopped with Java Service Wrapper. > > How could the application monitor whether the required services are up > and running? > > Thanks, > > Marc > |