tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shapira, Yoav" <>
Subject RE: init servlet loaded twice
Date Fri, 19 Sep 2003 13:02:32 GMT

By the same token, it's legal for the container to swap out
load-on-startup servlet (i.e. their destroy() method will be called) as
it needs to balance user requests with system resources.  Accordingly,
many times a ServletContextListener is a better choice than a
load-on-startup servlet.

Yoav Shapira
Millennium ChemInformatics

>-----Original Message-----
>From: Chris Rolfe []
>Sent: Thursday, September 18, 2003 5:16 PM
>To: Tomcat Users List
>Subject: Re: init servlet loaded twice
>I've noticed that load-on-startup also causes an extra instances of
>I came across another thread on multiple inits (Sun forum?). The gist
>that it's legitimate for the container to instantiate several of your
>Makes sense if you think about it. It's a "class" after all.
>on 9/18/03 12:38 PM, Phillip Qin wrote:
>> I was looking at my webapp log this afternoon. I use tomcat + log4j +
>> struts. In the log, I found that my InitServlet was loaded twice. One
>> Thread-xxx, the other under HostConfig[localhost]. Could any body
>> explain?
>> PQ
>To unsubscribe, e-mail:
>For additional commands, e-mail:

This e-mail, including any attachments, is a confidential business communication, and may
contain information that is confidential, proprietary and/or privileged.  This e-mail is intended
only for the individual(s) to whom it is addressed, and may not be saved, copied, printed,
disclosed or used by anyone else.  If you are not the(an) intended recipient, please immediately
delete this e-mail from your computer system and notify the sender.  Thank you.

View raw message