When you run Oracle ATG Web Commerce applications on WebLogic, WebLogic’s JSP container manages JSP compilation. If you are running WebLogic in development mode, modified pages are automatically recompiled when they are requested, ensuring that the .java
files associated with the pages are up to date. To prevent performance degradation due to unnecessary page recompilation, when you run WebLogic 10 in production mode, page recompilation is automatically disabled (.jsp
files should not change on a production environment, so in theory recompilation will never happen; but disabling recompilation ensures that it will not be triggered by a timestamp change).
Although recent WebLogic versions automatically disable page recompilation in production mode, you may want to manually disable recompilation if you are in a testing phase, but not yet running in production mode. Unnecessary recompilation may distort performance tests and slow down your quality assurance process.
To disable page recompilation, create a weblogic.xml
file (or modify an existing one) in the WEB-INF
directory of each web application you want to include in your EAR file. In the weblogic.xml
file, set these two parameters to -1:
pageCheckSeconds
specifies the interval in seconds between stale checks for an individual JSP. When a request for a JSP is received, if the last stale check on this page was longer ago than the number of seconds thatpageCheckSeconds
is set to, a new stale check is performed, and if the page is determined to be stale, it is recompiled. The default in development mode is 1 second. Setting this parameter to -1 disables stale checking.servet-reload-check-secs
specifies the interval in seconds between checks of a web application’sWEB-INF/classes
directory to see if any servlets have been recompiled (and therefore need to be reloaded). The default in development mode is 1 second. Setting this parameter to -1 disables checking.
The following example illustrates disabling both of these checks in the weblogic.xml
file:
<weblogic-web-app> <container-descriptor> <servlet-reload-check-secs>-1</servlet-reload-check-secs> </container-descriptor> <jsp-descriptor> <page-check-seconds>-1</page-check-seconds> </jsp-descriptor> </weblogic-web-app>