*
The moose likes Struts and the fly likes Context Reload Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Context Reload" Watch "Context Reload" New topic
Author

Context Reload

Wagner Danda Da Silva Filho
Ranch Hand

Joined: Mar 21, 2003
Posts: 80
Does anybody knows why my application context (in tomcat) gets fully reloaded after I change a simple Action class? I mean, if I change a "if" condition and build the application in the MyEclipse, all the application gets reloaded, and I have to wait almost 80 seconds to it do all the work... My framework uses Spring+Struts+Hibernate.

Thanks in advance,
Wagner Danda


SCJP, SCWCD
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
Action classes, like servlets are multi-threaded classes that remain resident in memory as long as the application is running. I'm guessing that somehow MyEclipse recognizes that when you change an Action, it won't become effective unless you restart the web application, so it restarts the application.


Merrill
Consultant, Sima Solutions
Wagner Danda Da Silva Filho
Ranch Hand

Joined: Mar 21, 2003
Posts: 80
Thanks Merrill, but in another project that uses only Struts+Hibernate this Action classes works perfectly! Just like updating a jsp page, the reload is NOT reloaded but the class source is.

Does anybody knows a good solution to develop java code in projects that takes long time to reload the context? It's so boring and counter-productive having to wait for 80-90 seconds every time I modify an Action class.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Context Reload
 
Similar Threads
programmably reload servlet context data
restarting the server
Caching while data changes on a daily basis
reload the command cache automatically
Context Reload Problem