Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Tomcat's restarts : how to decrease

 
Gagan Indus
Ranch Hand
Posts: 346
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Every time i
- recompile my servlet
- make little change to DD ( web.xml )
i have to restart Tomcat to make it recognize new changes.
Is their any explicit way to tell Tomcat that " Look i have done few changes , you plz reload this whole web-application again " , without restarting it.
( One almost-near trick i found in Tomcat's server.xml is <context reloadable="true"> . Is it best way . Am i on right track? )

------------------
Gagan (/^_^\) SCJP2
Die-hard JavaMonk -- little Java a day , keeps u going .
 
ashok khetan
Ranch Hand
Posts: 153
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Gagan! I think using Tomcat,everytime u will have to start it again to reflect the changes...U can try resin's web-server(link on javaranch-scwcd links page)...it's very good for testing the sample servlets...has good features like automatic compilation of ur java file, no caching of ur pages.
ashok.
 
Sreenivasa Majji
Ranch Hand
Posts: 224
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As Ashok mentioned, use Resin (http://www.caucho.com), it's faster than Tomcat and simple. No need to restart the server for any changes in either Servlet/JSP. Ofcourse it's my favorite one.
------------------
Sreenivasa Kumar Majji
Sun Certified Java Programmer
SCJP Mock Test
 
Gagan Indus
Ranch Hand
Posts: 346
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thankx Ashok , Sreenivasa , for the Resin Tip-off

Yes i installed Resin2.0.3 , and its seems great , in regard :
- That it automatically pick-up my recompiled servlets
- Also recongnize changes in DD , automatically , without restarts !
- Provides a small-window with two radio buttons , for Quick restart , if the need be .
Life gonna be little easier now . thankx u guyz

One little problem tho , If i map a name 'Serve' to my servlet 'MeriServlet' in web-application 'meriapp' , then following URL : http://localhost:8080/meriapp/servlet/Serve
should invoke 'MeriServlet' , right?
Well , it is doing this correctly in Tomcat , but in Resin it gives http-404 error .Any idea?

------------------
Gagan (/^_^\) SCJP2
Die-hard JavaMonk -- little Java a day , keeps u going .
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic