This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
WE are using tomcat4.31.1 in which your main application is running on UNIX server.Now some of the thread based application we running separately using command line which is independent of tomcat server. Now i want to run that thread based application when the tomcat server starts i.e onload.
Please can anybody tell me how to make run different thread based application using tomcat server onload event.
If the application you need to run is written in Java and you have access to the API (other than the already mentioned command line access) you might want to call it in process right from your webapp.
The context listener won't really run it when Tomcat starts up. It will run it when the application it is housed in starts up, which may or may not suite your needs. Another thought is to call it from the Tomcat wrapper scripts.
Without knowing more about this application, it is hard to say which is the best approach from here.