tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Glenn Nielsen <>
Subject Jasper 2 Synchronized JSP compiles
Date Wed, 04 Dec 2002 15:04:35 GMT
I have some ideas on how invoking the javac compiler for compiling JSP pages can be
improved.  Currently Jasper 2 uses ant to do compiles from within Tomcat which are

There are currently several problems.

1. The known javac memory leak.

2. JSP page compiles are synchronized.

3. Jikes currently can't be configured for windows because the windows build of
    jikes doesn't support -encoding.

4. We may be getting some bug reports related to this problem noted in the Ant
    documentation for the javac task:

Windows Note:When the modern compiler is used in unforked mode on Windows, it locks up the
files present in the 
classpath of the <javac> task, and does not release them. The side effect of this is
that you will not be able to delete 
or move those files later on in the build. The workaround is to fork when invoking the compiler.


Change Jasper 2 so that it tells ant to fork the javac compile.  This should remove the need
to synchronize the compiles.  It will also move java compilation outside of the JVM process
Tomcat is running in saving JVM heap memory and reducing GC overhead from objects created
JSP compiles.  This could be done by just adding another parameter called "fork" to the
JspServlet paramters. If fork=true ant forks the javac compile and no synchronization is done.
The default for fork would be false.




To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message