A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Android Security Essentials Live Lessons
this week in the
how to starts threads when servere starts up
Joined: Jun 11, 2009
Jun 19, 2009 06:31:50
In my application i am using threads that process some commands,
these threads need to be run always, so
i need to start these threads when server starts up.
any help greatly appriciated
Joined: Feb 27, 2009
Jun 19, 2009 08:02:23
You can have a
servlet context listener
. This would run anytime the server is started or reloaded (hot deployed) as long as it was in the web.xml.
Here is an
of how to set it up in the web.xml.
Don't get me started about those stupid
subject: how to starts threads when servere starts up
threads are started when JVM starts
access Object in collection of Threads
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014