Hello Glenn,
Do you know how do I unsubscribe from the list?
Thursday, April 12, 2001, 3:01:58 PM, you wrote:
GN [EMAIL PROTECTED] wrote:
On Thu, 12 Apr 2001, Luise Massimo wrote:
Hi all,
i have a simple question for which i haven't found an answare by myself: why
for the same JSP page tomcat generate a new java/class file in work dir for
every modification ?
Reloading issues.
"Normal" reloading ( that is used for regular servlets ) is implemented by
replacing the ClassLoader ( after you load a class with a class loader,
you just can't load a newer version ). This creates a number of problems -
all other servlets and classes must be reloaded, session objects and
attributes must also be reloaded ( class loaders define separate
namespaces, objects loaded with sibling loaders can't communicate ).
Jasper ( and any other system that generates servlets ) has another option
- to generate a new class name and use the old loader. Given that JSPs are
typically modified many times this saves a lot of overhead.
This is not an absolute requirement - it's easy to change jasper to use
the "servlet" reloading mechanism ( unfortunately you can't use versioning
on regular servlets - since the class name is fixed ).
Costin
GN Reloading is not an issue in the Tomcat 4 version of Jasper. It no longer
GN uses the .java/.class versioning system because it uses a URLClassLoader for
GN each JSP page compiled into a servlet. That way if the page is recompiled
GN the URLClassLoader for the JSP page itself can be dumped without affecting
GN the rest of the Context.
GN Regards,
GN Glenn
GN --
GN Glenn Nielsen [EMAIL PROTECTED] | /* Spelin donut madder|
GN MOREnet System Programming | * if iz ina coment. |
GN Missouri Research and Education Network | */ |
GN --
--
Best regards,
Gazizmailto:[EMAIL PROTECTED]