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
synchronized.
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.
Recommendation:
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 for
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.
Comments?
Regards,
Glenn
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
- Re: Jasper 2 Synchronized JSP compiles Glenn Nielsen
- Re: Jasper 2 Synchronized JSP compiles Costin Manolache
- Re: Jasper 2 Synchronized JSP compiles Remy Maucherat
- Re: Jasper 2 Synchronized JSP compiles Kin-Man Chung