----- Original Message -----
From: "Peter Desjardins" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <users@tomcat.apache.org>
Sent: Thursday, August 14, 2008 5:00 PM
Subject: Re: Hot redeploying a WAR - HTML is not refreshed
Thanks for the information.
I know it is not the browser caching. I've tried both IE and Firefox,
clearing all caches and refreshing.
I did look more closely at what Tomcat is doing when it hot redeploys
my WAR file. I'm using an unmodified copy of Tomcat to test this
issue. So Tomcat deploys the new HTML files here:
C:\apache-tomcat-6.0.18\webapps\war-file-name\
But it leaves the old HTML files here:
C:\apache-tomcat-6.0.18\work\Catalina\localhost\war-file-name\
And the browser is getting the old HTML files.
If I shut down the server, delete C:\apache-tomcat-6.0.18\work\, and
restart the server, the browser sees the new HTML files.
Is deleting the "work" directory standard practice for completely
refreshing web content? I can't do it while Tomcat is accessing the
files. Or is there a configuration option that will cause Tomcat to
delete and recreate the work directories when redeploying?
Again, thank you.
Peter Desjardins
Peter... I dont know... I cant get it to do anything like that...
Try with something that isnt your application, like the examples that come
with TC...
For example.... view a JSP or an HTML example...
Then open the unpacked webapp cal1.jsp example... change the title, and
refresh the browser..
Note I have not even told TC to reinstall the webapp.... and it changes....
it knows the html or web app has changed...
I've never had to touch a work file ever... imagine if we did have to delete
it on a deploy, ouch!
No there is something else going on... I'm wondering if its not worth trying
a diff version of TC just to elim that as well, maybe we got a diff build...
You see... if say a servlet is busy... and you drop a new webapp in.... what
TC will do is make sure all the busy stuff finishes, and then it will only
change (redeploy the web app)....
The other thing is that I cant actually recall ever seeing an HTML file in
the work folder...
I see stuff like...
basic_002darithmetic_jsp.class
basic_002darithmetic_jsp.java
which is what it is used for... ie to hold the compiled JSP's...
if you using HTML to describe JSP's then we already have crossed lines...
I dont know if you ever noticed, but for example if you cchange tomcats
default root index.jsp... it aslo doesnt change, but thats because its
precompiled into the app...
Done guessing... I cant make it do it on my apps... best of luck ;(
Aaaaaaaaaaaaah just had another brain wave... it happen, albeit seldomly ;)
Next time it happens... check the
conf\Catalina\localhost THE WEBAPP CONTEXT FILE...
I bet its still pointing at your dev environment.... delete that, then drop
the webapp in...
You see TC almost may be saying... the idiot (just kidding) has dropped a
webapp into me... but the one I'm actually using in the IDE, is still cool,
so I'll just ignore the other one....
When you done developing from an IDE... esp Netbeans... you must undeploy
it... else it still uses the webapp in the build folder of NB...
Ok now I really am done guessing...
---------------------------------------------------------------------------
HARBOR : http://www.kewlstuff.co.za/index.htm
The most powerful application server on earth.
The only real POJO Application Server.
See it in Action : http://www.kewlstuff.co.za/cd_tut_swf/whatisejb1.htm
---------------------------------------------------------------------------
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]