You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Andreas Sheriff <ma...@asheriff.com> on 2000/12/23 07:49:11 UTC

Reloading JSP is a bug?

Hi,

JGuru states that there is a bug in Tomcat 3.1 where a jsp page converted to
a servlet still loads, even though the original jsp page was deleted
(http://www.jguru.com/jguru/faq/view.jsp?EID=224108).  Is this still a bug
in 3.2?

I have Tomcat 3.2 installed on a Linux platform, but I find myself having to
restart Tomcat whenever I want the jsp to reflect any change in the
generated servlet.  I have even tried deleting the source and class files in
the work directory, but that doesn't work.  Does anyone have any ideas on
how to correct this?  Or do I have to wait for Tomcat 4.0 to be completed.

Andreas Sheriff


Re: Reloading JSP is a bug? [humor]

Posted by Andreas Sheriff <ma...@asheriff.com>.
----- Original Message ----- 
From: "Ted Husted" <ne...@husted.com>
To: "Tomcat User List" <to...@jakarta.apache.org>
Sent: Saturday, December 23, 2000 3:15 AM
Subject: Re: Reloading JSP is a bug? [humor]


> On 12/23/2000 at 2:29 AM Andreas Sheriff wrote:
> > To complete the pedantic discussion, the difference between a bug and
> a feature is that a bug is unintended.
> 
> Oh, come-on, completing a pendantic discussion is clearly an oxymoron. 
> 
> Given the usual lack of architectural documentation, what was intended
> is anyone's guess. And, even then, some of the world's best features
> have been unintended (at least by us mere mortals) ;-). 
> 
> So the pendantic slice and dice quickly degrades to feature, unintended
> feature, intended but undocumented feature, and if all else fails, and
> the behaviour is clearly objectionable to any reasonable observer, and
> even cannot be spun by a marketing rep with a straight face, then it
> may actually be (ahemm) a bug. 

Good point.  :)

And the sad thing is, I know exactly what you're talking about.

> 
> 
> -- Ted Husted, Husted dot Com, Fairport NY USA.
> -- Custom Software ~ Technical Services.
> -- Tel 716 425-0252; Fax 716 223-2506.
> -- http://www.husted.com/
> 
> 


Re: Reloading JSP is a bug? [humor]

Posted by Ted Husted <ne...@husted.com>.
On 12/23/2000 at 2:29 AM Andreas Sheriff wrote:
> To complete the pedantic discussion, the difference between a bug and
a feature is that a bug is unintended.

Oh, come-on, completing a pendantic discussion is clearly an oxymoron. 

Given the usual lack of architectural documentation, what was intended
is anyone's guess. And, even then, some of the world's best features
have been unintended (at least by us mere mortals) ;-). 

So the pendantic slice and dice quickly degrades to feature, unintended
feature, intended but undocumented feature, and if all else fails, and
the behaviour is clearly objectionable to any reasonable observer, and
even cannot be spun by a marketing rep with a straight face, then it
may actually be (ahemm) a bug. 


-- Ted Husted, Husted dot Com, Fairport NY USA.
-- Custom Software ~ Technical Services.
-- Tel 716 425-0252; Fax 716 223-2506.
-- http://www.husted.com/



Re: Reloading JSP is a bug?

Posted by Andreas Sheriff <ma...@asheriff.com>.
----- Original Message -----
From: "Craig R. McClanahan" <Cr...@eng.sun.com>
To: <to...@jakarta.apache.org>
Sent: Friday, December 22, 2000 11:55 PM
Subject: Re: Reloading JSP is a bug?


> Andreas Sheriff wrote:
>
> > Hi,
> >
> > JGuru states that there is a bug in Tomcat 3.1 where a jsp page
converted to
> > a servlet still loads, even though the original jsp page was deleted
> > (http://www.jguru.com/jguru/faq/view.jsp?EID=224108).  Is this still a
bug
> > in 3.2?
> >
>
> Well, you have to get into a pedantic discussion of "bug" versus "feature"
to
> decide what's really going on :-)  When you are outside the scope of the
> relevant specifications (as we are here), it can get difficult to know
> sometimes.
>

To complete the pedantic discussion, the difference between a bug and a
feature is that a bug is unintended.

> >
> > I have Tomcat 3.2 installed on a Linux platform, but I find myself
having to
> > restart Tomcat whenever I want the jsp to reflect any change in the
> > generated servlet.  I have even tried deleting the source and class
files in
> > the work directory, but that doesn't work.  Does anyone have any ideas
on
> > how to correct this?  Or do I have to wait for Tomcat 4.0 to be
completed.
> >
>
> Let's divide this world into at least two sub-worlds:
>
> * I changed the JSP source code itself.  All JSP engines are required
>   by the specs to recompile the page in this case, and therefore reflect
>   the changes.  I've had no problems with this in 3.2 or 4.0.
>
> * I changed a bean class used in a JSP page, without updating the JSP
>   page itself.  The 3.1 and 3.2 approaches to auto-reloading a web app
>   do not correctly detect all cases of this.  The 4.0 approach should do
so
>   correctly for classes in WEB-INF/classes (not yet for classes in JAR
>   files under WEB-INF/lib).
>
> Under *no* version of Tomcat will you be able to update classes that were
loaded
> via the CLASSPATH, and have them reflected in changed behavior in your web
app,
> without restarting Tomcat.

I don't have my JSP files, nor the work directory in my classpath, yet,
still, they do not reload without restarting Tomcat.  Even if I delete the
source and class files in the $TOMCAT_HOME/work directory they still get
regenerated from the old JSF source.  Is Tomcat caching my JSF file
somewhere?  If so, how do I get it to stop?

By the way, I have my JSF files on a network drive, however, I don't think
that the NFS is caching the file, because it sees the new copy when I
restart Tomcat, not the NFS.

How stable is Tomcat 4.0?  Can I install it instead of 3.2 without error?

>
> >
> > Andreas Sheriff
>
> Craig McClanahan
>
>


Re: Reloading JSP is a bug?

Posted by "Craig R. McClanahan" <Cr...@eng.sun.com>.
Andreas Sheriff wrote:

> Hi,
>
> JGuru states that there is a bug in Tomcat 3.1 where a jsp page converted to
> a servlet still loads, even though the original jsp page was deleted
> (http://www.jguru.com/jguru/faq/view.jsp?EID=224108).  Is this still a bug
> in 3.2?
>

Well, you have to get into a pedantic discussion of "bug" versus "feature" to
decide what's really going on :-)  When you are outside the scope of the
relevant specifications (as we are here), it can get difficult to know
sometimes.

>
> I have Tomcat 3.2 installed on a Linux platform, but I find myself having to
> restart Tomcat whenever I want the jsp to reflect any change in the
> generated servlet.  I have even tried deleting the source and class files in
> the work directory, but that doesn't work.  Does anyone have any ideas on
> how to correct this?  Or do I have to wait for Tomcat 4.0 to be completed.
>

Let's divide this world into at least two sub-worlds:

* I changed the JSP source code itself.  All JSP engines are required
  by the specs to recompile the page in this case, and therefore reflect
  the changes.  I've had no problems with this in 3.2 or 4.0.

* I changed a bean class used in a JSP page, without updating the JSP
  page itself.  The 3.1 and 3.2 approaches to auto-reloading a web app
  do not correctly detect all cases of this.  The 4.0 approach should do so
  correctly for classes in WEB-INF/classes (not yet for classes in JAR
  files under WEB-INF/lib).

Under *no* version of Tomcat will you be able to update classes that were loaded
via the CLASSPATH, and have them reflected in changed behavior in your web app,
without restarting Tomcat.

>
> Andreas Sheriff

Craig McClanahan