tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kitching Simon <Simon.Kitch...@orange.ch>
Subject RE: Session Info Sharing
Date Fri, 27 Oct 2000 17:05:55 GMT


> -----Original Message-----
> From:	Nicolas Gauthier [SMTP:gauthier@azalee.cst.cnes.fr]
> Sent:	Friday, October 27, 2000 5:50 PM
> To:	tomcat-user@jakarta.apache.org
> Subject:	Re: Session Info Sharing
> 
> >         [Kitching Simon]
> >         I have a docBase outside tomcat, and preload servlets fine.
> >
> >         in $TOMCAT_HOME/conf/server.xml:
> >                 <Context path="" docBase="/somepath/docroot" debug="0"
> > reloadable="false" >
> >                 </Context>
> >
> >         in /somepath/docroot/WEB-INF/web.xml:
> >             <servlet>
> >                 <servlet-name>initializerServlet</servlet-name>
> >
> <servlet-class>com.acme.InitializerServlet</servlet-class>
> >                 <load-on-startup>1</load-on-startup>
> 
> Ok, good to know you're doing it !
> 
> And ... when is this servlet preloaded: is it when you start the server ?
> 
	[Kitching Simon]  
	Definitely; the servlet logs a whole bunch of messages
	(using the log4j logging module) and they all come out 
	*before* the webserver starts accepting http requests.
	In fact, I have two servlets: one at load-on-startup=1,
	which initializes critical stuff, and one at load-on-startup=2,
	and they get run in the correct order.

> If yes, does this mean that if you have 10 web-apps, each of which has one
> preloaded servlet, Tomcat will preload them all ?
> 
	[Kitching Simon]  
	This I can't answer, as I have only one web-app per tomcat.
	I would expect that the above is right.

	By the way, I am using tomcat3.1 (and have been hanging
	on for an official 3.2 release for what seems long enough to
	raise a family...)

> Thanks for you answer,
> 
> Nicolas.
> http://www.vieuxport.com/nico

Mime
View raw message