During compilation of a JSP file, it will be first converted into a .java file then .class file after that it will be loaded by the container to serve request. I want to know where container put converted .java and .class file. will it be available after request has been fulfilled.
David Newton wrote:There's a "work" directory that contains each app's intermediate files.
Thanks :) I did not get any intermediate file under work folder. Is there any way to configure where to put compiled JSP's intermediate java and class file ?
Only in a general way. You can set the CATALINA_BASE environment variable, and that will retarget the parent directory for the work directory - as well as the temp directory (if not overridden), the logfiles, and the conf directory. On some operating systems, you can retarget the work directory itself via a filesystem link (which is occasionally useful if filesystem space is tight or you're based on read-only media).
You don't own the java or classfiles that come from JSPs and shouldn't be meddling with them in the course of ordinary application systems. It's fully within the rights of an appserver to discard the Java source entirely (or even bypass source generation) and to generate the classes directly into RAM without ever keeping permanent copies of the compiled JSPs anywhere in the filesystem. It's even possible that future Tomcat releases might choose to do so.
So unless your interest is academic or you plan to fork Tomcat and pay the expense of keeping the fork up to date as new Tomcat releases emerge, I recommend not worrying about it.
Blitzlügen - Lies or information broadcast, but when called out the broadcaster does little or nothing is done to correct them, thus allowing those who wish to believe to accept them as truth.
Lügensturm - A barrage of Blitzlügen fired in such quick succession that it is essentially impossible to correct them all.