Return-Path: Delivered-To: apmail-jakarta-tomcat-dev-archive@apache.org Received: (qmail 44209 invoked from network); 8 Aug 2002 17:05:01 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 8 Aug 2002 17:05:01 -0000 Received: (qmail 11076 invoked by uid 97); 8 Aug 2002 17:05:21 -0000 Delivered-To: qmlist-jakarta-archive-tomcat-dev@jakarta.apache.org Received: (qmail 11061 invoked by uid 97); 8 Aug 2002 17:05:20 -0000 Mailing-List: contact tomcat-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Developers List" Reply-To: "Tomcat Developers List" Delivered-To: mailing list tomcat-dev@jakarta.apache.org Received: (qmail 11049 invoked by uid 98); 8 Aug 2002 17:05:20 -0000 X-Antivirus: nagoya (v4198 created Apr 24 2002) Message-ID: <3D52A431.1090709@sun.com> Date: Thu, 08 Aug 2002 10:02:41 -0700 From: Patrick Luby User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en-US; rv:1.1b) Gecko/20020722 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Tomcat Developers List Subject: Re: [PROPOSAL] Have Bootstrap and BootsrapService share startup/shutdown code References: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Costin, costinm@covalent.net wrote: > On Thu, 8 Aug 2002, Patrick Luby wrote: > > > > > The way I see it: > > Bootstrap.java -> creates the classpath for server, creates > and load Catalina.java ( using Class.forName() ). No dependency on > tomcat - except possibly introspection. > > Catalina.java -> 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 Bootstrap.java's classloader, etc. setup? Right now, all of this is buried in main() instead of a method that commons-daemon could access. > > Catalina.java 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 Bootstrap.java 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, Bootstrap.java 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 -- ________________________________________________________________ Patrick Luby Email: patrick.luby@sun.com 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: