Write a class that implements a ServletContextListener and then add it to your web.xml as a listener. It creates a hook for startup as well as shutdown. I use this to build my own database pool and store it as an attribute of the servlet context for later.

--David

Trumml wrote:
I'm using JBoss 327 with Tomcat 5.
My applications running inside JBoss (Tomcat) need some kind of "runtime
initializing". For example when a MBean is deployed, inside the start()
method my runtime will be initialized.
How can I achieve this with a WAR file? I want to call a method once when my
WAR file is deployed.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to