Yes, that would work if I had a handle to the embedded instance. The thing is that embedded tomcat is running in a separate VM and I need to be able to shut it down. I don't really need to use Embedded class if only I could get Bootstrap or Catalina classes to work without having to have the whole tomcat directory on disk.
-----Original Message----- From: news on behalf of Bill Barker Sent: Wed 12/14/2005 8:14 PM To: users@tomcat.apache.org Subject: Re: starting and stopping Tomcat from Java code Urm, something like: tomcat.stop(); where 'tomcat' is your Embedded instance? "Oleg Lebedev" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Hello, I am trying to configure, start and then shutdown Tomcat from my Java class. I am planning to have all the jars required by Tomcat on the classpath and I would like to be able to specify the port number and host using method calls. I would prefer not to ship Tomcat configuration files, such as server.xml with my application and be able to configure Tomcat from code before starting it. I tried using Boostrap class, but it requires catalina.home and catalina.base, which I would like to avoid using. I tried using Embed class and it worked, but I still had to set catalina.home so that it can find tomcat-users.xml. But, this is acceptable. I have not been able to shut Tomcat down from my Java code. Note that I won't have a handle to the Catalina instance started, because Tomcat needs to be started before my application starts in a separate VM, and then killed when my application exists. I would appreciate any feedback on how to do this or what Tomcat classes I should take a look at. Thanks. Oleg --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. If you have questions about this email, please contact the IT Help Desk. Mail --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]