If you create that as a servlet, you can set the startup to 1 which will call it each
time the webserver starts.
Is that what you are looking for?
<servlet>
<servlet-name>servletname</servlet-name>
<servlet-class>com.skp.someclass</servlet-class>
<init-param>
<param-name>hello</param-name>
<param-value>world</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
When the server starts it sees this class as a startup class and immediately executes
its init.
Scott Purcell
Vertis Corporation
-----Original Message-----
From: Chandra Gottipati [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 29, 2003 9:45 AM
To: Tomcat Users List
Subject: Starting a Clean-up program
I have a static method that starts a thread with a class that does some
clean-up tasks.
public static void init(){
Thread t = new Thread( new ClearUserHashMapClient() );
t.start();
}//init
How can I configure my webapp to call this init() method when I deploy my
war file on Tomcat.
Thanks,
Chandra.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]