Brian,

what i had in mind was that the AxisServlet when it starts up, it will
start up the JMX thingy with the AxisEngine that it creates/uses. Will
this not work?

-- dims


----- Original Message -----
From: Brian Dillon (ext. 944) <[EMAIL PROTECTED]>
Date: Wed, 30 Jun 2004 10:41:35 +0100
Subject: Solution : Starting/Stoping Services on Demand
To: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>









Hi,

 

A short while ago I 
asked about stoping and starting Axis Services on demand. Davanum 
Srinivas provided a way to do this through the AdminServlet (Thanks
Dims). However
I was looking for a way that would make it possible to do through JMX or the 
like. The main issue I had was that I couldn't get a reference to the
AxisEngine
which was in memory (If I created a new one it dodn't share the same 
configuration and thus couldn't see/control the deployed 
services).

 

I have found a workaround to my 
problem of not being able to locate the correct Axis Engine in memory.
If I have
a new deployed Axis Service (AdminService) then I can get the correct Axis 
Engine through;

 

AxisEngine.getCurrentMessageContext().getAxisEngine()

 

To get the SOAPService Object 
corresponding to the service I wish to stop/start I can use;

 

AxisEngine.getCurrentMessageContext().getAxisEngine().getService(serviceName)

 

And then on the SOAPService method 
stop() and start() can be called;

 

As I mentioned this 
must be called within the context of a service call so unless we want to start 
shipping an AdminService as part of Axis this part would be left up to people 
themselves to call in their own AdminService.

 

Thanks,

 

Brian.



**********************************************************************

The information contained in this e-mail is confidential, may be
privileged and is intended only for the user of the recipient named
above.  If you are not the intended recipient or a representative of
the intended recipient, you have received this e-mail in error and
must not copy, use or disclose the contents of this e-mail to anybody
else.  If you have received this e-mail in error, please notify the
sender immediately by return e-mail and permanently delete the copy
you received.  This e-mail has been swept for computer viruses. 
However, you should carry out your own virus checks.

Registered in Ireland, No. 205721.  http://www.FINEOS.com

**********************************************************************







-- 
Davanum Srinivas - http://webservices.apache.org/~dims/

Reply via email to