Re: Problem with refreshing JSP

2005-07-21 Thread Christoph Kutzinski

Travis Stevens wrote:
The other thing to note about reloading JSPs is that tomcat 5.5 seems to 
copy ones web context directory into its own webapps directory.  Any 
changes to the original JSPs will not show up unless you physically copy 
the JSP from the original directory to the webapps directory.


I haven't observed this behavior with my Tomcat 5.5.
Maybe you have set antiResourceLocking=true or something like this. In 
this case I think tomcat will copy all the files.



Christoph


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem with refreshing JSP

2005-07-21 Thread Travis Stevens


The other thing to note about reloading JSPs is that tomcat 5.5 seems 
to copy ones web context directory into its own webapps directory.  
Any changes to the original JSPs will not show up unless you 
physically copy the JSP from the original directory to the webapps 
directory.



I haven't observed this behavior with my Tomcat 5.5.
Maybe you have set antiResourceLocking=true or something like this. 
In this case I think tomcat will copy all the files.


I double checked and antiResourceLocking is false.  Is there some other 
configuration property somewhere that would indicate that the webapp is 
to be copied?  I use the 5.5.9 tomcat for Linux pretty much right out of 
the box.


-Trav

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem with refreshing JSP

2005-07-20 Thread Travis Stevens
The other thing to note about reloading JSPs is that tomcat 5.5 seems to 
copy ones web context directory into its own webapps directory.  Any 
changes to the original JSPs will not show up unless you physically copy 
the JSP from the original directory to the webapps directory.


I use the maven:install goal which worked well with tomcat 5.0.  It 
created a directory (say /home/blah/project/target/project_name).  If I 
changed a JSP, I simply ran war:webapp which would
copy all the changed files into the said directory.  With tomcat 5.5, 
this does not work because the tomcat seems to care less about the 
specified directory after installing the webapp. 

To work around this, my web app build target (maven.war.webapp.dir) is 
now /home/blah/bin/tomcat/webapps/project_name (pointing directly to the 
tomcat installation).  At first I simply used the war:webapp goal, but 
the context.xml file was not picked up.  Now I used the tomcat:install 
goal again which builds the webapp in the tomcat webapps directory and 
then uses the tomcat manager to install the directory.  I should 
probably set autoDeploy to false so that conflicts do not occur between 
the auto deploy mechanism and the tomcat manager.


Anyway, I don't think this is an elegant solution, so if anyone has any 
other suggestions on how to handle this, please let me know.


-Trav

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem with refreshing JSP

2005-07-12 Thread Rahul Joshi
Hi,
 
It is Tomcat that has these compiled files which it continues to read from 
work/Catalina/localhost/ instead of the new ones. The questions is how do we 
make Tomcat clear or over-write these stored compiled files. 
 
Thanks, Rahul.

Gurumoorthy [EMAIL PROTECTED] wrote:
Well,
Is it the browser or tomcat ? if it is the browser then you need to add the 
no-cache headers to the response 

regards
Guru
- Original Message - 
From: Rahul Joshi 
To: 
Sent: Tuesday, July 12, 2005 1:50 AM
Subject: Problem with refreshing JSP


 Hello:

 I am using Tomcat5.5.7 with Eclipse environment.
 The problem I was facing was that inspite of changing or deleting  
 re-copying and compiling a JSP page (after re-starting the tomcat server), 
 the browser was reading the old compiled file from 
 work/Catalina/localhost/...

 I solved the problem by deleteing the contents of work/Catalina/localhost.

 Is there a programmatic, I mean, by setting some Tomcat property solution 
 to this??

 Any help is greatly appreciated. Thanks!
 Rahul.
 



Re: Problem with refreshing JSP

2005-07-12 Thread Rob Hills
Hi Rahul,

On 12 Jul 2005 at 8:19, Rahul Joshi wrote:

 It is Tomcat that has these compiled files which it continues to read
 from work/Catalina/localhost/ instead of the new ones. The questions
 is how do we make Tomcat clear or over-write these stored compiled
 files. 

If you set the Reloadable attribute of your application's Context element to 
True you will find that Tomcat will recompile any JSP file 
shortly after it changes ( see 
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/context.html ).

As described in the documentation, this can slow down the performance of your 
application so it's best to switch it off on a production 
server.

Rob Hills
Western Australia

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Problem with refreshing JSP

2005-07-12 Thread Christoph Kutzinski

Rob Hills wrote:

Hi Rahul,

On 12 Jul 2005 at 8:19, Rahul Joshi wrote:



It is Tomcat that has these compiled files which it continues to read
from work/Catalina/localhost/ instead of the new ones. The questions
is how do we make Tomcat clear or over-write these stored compiled
files. 



If you set the Reloadable attribute of your application's Context element to True you will find that Tomcat will recompile any JSP file 
shortly after it changes ( see http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/context.html ).


As described in the documentation, this can slow down the performance of your application so it's best to switch it off on a production 
server.


Actually reloadable=true makes tomcat watch for changes  in 
/WEB-INF/classes/ and /WEB-INF/lib (see again 
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/context.html ) 
which is indeed a costly operation.
Watching for changes to the JSPs is done somewhere else. If memory fails 
me not, it is in the server.xml file: an attribute of the JSPServlet 
element. Watching for JSP changes is not that costly. Unless you have a 
very high traffic site you can safely use it for your production site, too.



Christoph

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Problem with refreshing JSP

2005-07-11 Thread Rahul Joshi
Hello: 
 
I am using Tomcat5.5.7 with Eclipse environment. 
The problem I was facing was that inspite of changing or deleting  re-copying 
and compiling a JSP page (after re-starting the tomcat server), the browser was 
reading the old compiled file from work/Catalina/localhost/...
 
I solved the problem by deleteing the contents of work/Catalina/localhost. 
 
Is there a programmatic, I mean, by setting some Tomcat property solution to 
this??
 
Any help is greatly appreciated. Thanks!
Rahul.


Re: Problem with refreshing JSP

2005-07-11 Thread Gurumoorthy

Well,
Is it the browser or tomcat ? if it is the browser then you need to add the 
no-cache headers to the response 


regards
Guru
- Original Message - 
From: Rahul Joshi [EMAIL PROTECTED]

To: tomcat-user@jakarta.apache.org
Sent: Tuesday, July 12, 2005 1:50 AM
Subject: Problem with refreshing JSP



Hello:

I am using Tomcat5.5.7 with Eclipse environment.
The problem I was facing was that inspite of changing or deleting  
re-copying and compiling a JSP page (after re-starting the tomcat server), 
the browser was reading the old compiled file from 
work/Catalina/localhost/...


I solved the problem by deleteing the contents of work/Catalina/localhost.

Is there a programmatic, I mean, by setting some Tomcat property solution 
to this??


Any help is greatly appreciated. Thanks!
Rahul.




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]