You are viewing a plain text version of this content. The canonical link for it is here.
Posted to general@jakarta.apache.org by Martin Koistinen <ma...@koistinen.com> on 1999/11/18 20:11:56 UTC

Cached classes somewhere?

Something strange is happening.

I am working on a simple JSP.  Everything seems to be working just fine, 
but now, when I make a change to my *.jsp source and then execute it (via 
my browser), it takes a second (obviously compiling it for me) but then 
executes an old incarnation of it!

I'm somewhat puzzled here.  I've emptied out the "work" directory, 
restarted and cleared the caches of my browser (not sure how that could 
help, but just in case...) and the problem continues.

I've searched for answers online but cannot find the answer to this one.

What gives?

Martin Koistinen 

Re: Cached classes somewhere?

Posted by Tom Rodriguez <tr...@parc.xerox.com>.
Martin Koistinen wrote:
> 
> Something strange is happening.
> 
> I am working on a simple JSP.  Everything seems to be working just fine,
> but now, when I make a change to my *.jsp source and then execute it (via
> my browser), it takes a second (obviously compiling it for me) but then
> executes an old incarnation of it!
> 
> I'm somewhat puzzled here.  I've emptied out the "work" directory,
> restarted and cleared the caches of my browser (not sure how that could
> help, but just in case...) and the problem continues.

I had a similar problem that was caused by copies of the class files
produced from the JSP files ending up elsewhere in my classpath.  I was
using ant to build my own project and since it compiles anything that
end it .java, it was compiling the JSP .java files and putting .class
files in my class output directory.  Since the names generated for the
JSP .java files are very regular between runs, it's possible to get
collisions like this during development.  I've got a patch for
JspLoader.java that detects this situation.  I don't know if this is
your situation though.

tom