aspose file tools
The moose likes Servlets and the fly likes Reloading Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Servlets
Reply Bookmark "Reloading" Watch "Reloading" New topic
Author

Reloading

pravanya Gullapudi
Greenhorn

Joined: May 07, 2007
Posts: 16
how to reload the servlet automatically?
Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 8795

It is dependent on the container that you might use. Some has the option to automatically do it as and when you make changes to your servlet!


SCJP 1.4, SCWCD 1.4 - Hints for you, SCBCD Hints - Demnachst, SCDJWS - Auch Demnachst
Did a rm -R / to find out that I lost my entire Linux installation!
Hussam Bamatraf
Greenhorn

Joined: Aug 25, 2003
Posts: 14
Tomcat can reload your servlets if there is any change by specifying reloadable attribute to true in the Context element in server.xml file or your web application configuration file.
For example, go to <tomcat_home>\conf\Catalina\localhost\ and locate your_application_name.xml file (if your application config file is not listed here you can check for the <Context> attribute inisde server.xml file or create a new file with your application name inside <tomcat_home>\conf\Catalina\localhost\ folder), then add reloadable="true" as following:

if you create a new file configuration the above script is enough.
Please be warned the reloadable web application is much slower; therefore, it is not suitable for production use (use it for development stage only).


SCJP 90%<br />FileNet Certified Professional: Content Management Developer 92%<br />FileNet Certified Professional: Business Process Management Developer 92%
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Reloading