tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Patrick Luby <>
Subject Re: [PROPOSAL] Have Bootstrap and BootsrapService share startup/shutdown code
Date Thu, 08 Aug 2002 17:02:41 GMT
Costin, wrote:
> On Thu, 8 Aug 2002, Patrick Luby wrote:
> The way I see it: 
> -> creates the classpath for server, creates 
> and load ( using Class.forName() ). No dependency on
> tomcat - except possibly introspection. 
> -> main entry point into tomcat. It will have 
> setXXX methods ( in addition to the CLI ), start(), stop(),
> execute(). That's where I would do all the endoresed, policy
> settings and most of the logic, that's what applications 
> embeding tomcat will use
> All other classes should go to a compat/ directory and maintained
> for backward compat only. The commons-deamon can use introspection to 
> call start()/stop().

Wouldn't commons-daemon also want to use's classloader, 
etc. setup? Right now, all of this is buried in main() instead of a 
method that commons-daemon could access.

> will be useable as an ant task ( using execute() 
> and the setters ) and will be useable as an MBean ( using modeler ).
> All things that can be specified via CLI will be setable via
> setters.

Wouldn't we want to put execute() in since that is where 
all of the classloader magic is happening?

> Regarding the shutdown port: it is essential for me to make it
> optional ( so that ant can start catalina in process and then _return_ ).
> Ajp13 already implements a shutdown procedure - and I would rather
> use that. In addition JMX can be used to call the stop operation.

I agree. The BootstrapService does this very well. Hence, my proposal to 
share common methods. By sharing start() and stop() logic, would only need to have a command-line option (e.g. 
-noshutdownport) that bypasses the creation of the shutdown port. Right 
now, Bootstrap.main() has this shutdown port stuff really embedded in there.

Also, my hope is that we can have the shutdown port logic, when it is 
used, happen *before* the server is started so that you don't have to 
wait for the server to fully start before you can shutdown Tomcat.


Patrick Luby                     Email:
Sun Microsystems                         Phone: 408-276-7471
901 San Antonio Road, USCA14-303
Palo Alto, CA 94303-4900

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message