Hi Troy, Thanks a lot for your reply.
I considered this option first before I delved deep into internals of ManagerServlet. The thing is, I can Redirect the request to the managerServlet to start or stop the service and it works as intended in a sense that it starts or stops the web-app. But the problem is after a redirection, the response comes from ManagerServlet and I loose the control over what should be sent back to the user. Also I think it would be nice to have some sort of API that lets you handle other webapps rather than depending on the ManagerServlet. Anyways, please let me know your inputs on this. Thanks for your time, Sincerely, Shimol. On 6/26/06, Troy Davidson <[EMAIL PROTECTED]> wrote:
OK, Really simple/stupid question...why not use the Tomcat Manager to do this? You can have the controlling webapp open a url to the manager and have the controlling webapp pass a start/stop on the other webapp. Not sure if you looked at it or not, but had to ask. Here is a link for the manager: http://tomcat.apache.org/tomcat-5.5-doc/manager-howto.html#Supported%20Manager%20Commands Shimol Shah wrote: > Hi all, > > As I have also mentioned in one of my previous emails, I want to > start/stop > a web application from another webapplication. In my efforts to achieve > this, I came across ManagerServlet. All my efforts to bring the similar > functions in my web-app failed. > > So I went through the Tomcat API docs and found that it mentions that > ContainerServlet (which is implemented by ManagerServlet) is loaded by > Catalina class loader and not the standard web application class loader. > Thinking that it might be the issue that my application residing under > web-apps and not a part of the server folder, restricts its use of > Catalina > class loader, I moved the web app folder to server\webapps. That > didn't help > too. > > After that, I put only one servlet which implements ContainerServlet > from my > web-app to Manager webapp under /server/lib/webapps/manager/WEB-INF/lib, > where it started working without any other issues. I assume this is > working > before manager application has some special privileges to use Catalina > class > loader either by some descriptor or by other means. > > So it would really be helpful if anybody can give me some starting > pointers > where I can look for to find out how to change the class loader for > the web > apps so that I can keep using my webapp and can establish control over > other > web-application. > > And also on a side note, I would be thankfule if anybody can point me > to any > other existant ways to control other webapps from one web app. > > My primary purpose to establish control over other webapps is because my > product is running with different components running as different web > apps > and I want to create a management webapp that controls them. > > Any help is sincerely appreciated, > > Thanks, > Shimol. > -- ++++++++++++++++++++++++++++++++++ Troy Davidson Java Programmer PC/Web Team CMC/Flex 8520 South Sandy Parkway Sandy, UT 84070 (801) 365-5000 www.cmcflex.com --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]