uCosminexus Application Server, Web Container Functionality Guide

[Contents][Glossary][Index][Back][Next]

2.5.6 JSP Compilation results when JSP pre-compilation functionality is not used

When you do not use the JSP pre-compilation functionality, the JSP files are compiled during initial access to a JSP file. This subsection describes the JSP compilation results and the method of changing the output destination of the compilation results, when the JSP pre-compilation functionality is not used.

Organization of this subsection
(1) Lifecycle of JSP compilation results
(2) Maintaining the compilation results of JSP files
(3) Output destination of JSP compilation results

(1) Lifecycle of JSP compilation results

The lifecycle of the JSP compilation results when you do not use the JSP pre-compilation functionality is explained below:

Generating the compilation results
In the case you do not compile the JSP files beforehand by the JSP pre-compilation functionality, the JSP compilation results are generated when:
  • The JSP is first accessed
  • The Web application in which <load-on-startup> is specified for JSP in DD (web.xml) is started

Deleting the compilation results
The JSP compilation results are deleted when:
  • The J2EE application is un-deployed
  • The J2EE server is started#
  • The J2EE server is stopped#
#
If the setting specifies that the JSP compilation results are not to be maintained, the JSP compilation results are deleted. When the J2EE server is started, the compilation results are deleted to prepare for the forced termination of the server.

(2) Maintaining the compilation results of JSP files

If you do not perform JSP pre-compilation, with a Web container, you can specify whether to maintain the Java source files and class files that serve as JSP compilation results, when a J2EE server is restarted.

Customize the properties of the J2EE server to specify the settings for maintaining the compilation results of JSP files. For details on customizing the settings of the J2EE server operations, see 2.5.8 Execution environment settings (J2EE server settings).

Note

Points to be noted when a Web application is un-deployed
By default, the setting is specified to maintain the JSP compilation results. Even if you specify the settings to maintain the JSP compilation results, the JSP compilation results are deleted if a Web application is un-deployed. Consequently, the user need not delete the JSP compilation results when a server is restarted. After running a Web container by specifying the settings to maintain the JSP compilation results, if you do not need the JSP compilation results, un-deploy the J2EE application.
Hitachi recommends that you specify the settings to maintain the JSP compilation results.

(3) Output destination of JSP compilation results

When you do not implement the JSP pre-compilation functionality, the JSP compilation results are output to the temporary directory for JSP.

The following files are output:

  1. Java source files generated from JSP files
  2. Class file that compiles the Java source files mentioned in 1.
  3. Java source files generated from tag files
  4. Class file that compiles the Java source files mentioned in 3.

The default output destination and the configuration of the output destination directory are explained below:

For details on the output class names, see 2.5.7 Class names in JSP compilation results.

(a) Default output destination

When you do not execute the JSP pre-compilation functionality, the JSP compilation results are output to the directory for each Web application created under the temporary directory for JSP. The default temporary directory for JSP is at the following location:

In Windows
Cosminexus-installation-directory\CC\server\repository\server-name\web

In UNIX
/opt/Cosminexus/CC/server/repository/server-name/web

Note that the default value is set for the temporary directory for JSP. However, if necessary, you can change the default value. For details on changing the temporary directory for JSP, see 2.5.8 Execution environment settings (J2EE server settings).

The directory will be created for each Web application under the temporary directory for JSP and the JSP compilation results that exist in the relevant Web application will be output.

Note that the directory for the Web applications has the directory name based on the context root name. If the context root name includes a slash (/), dollar sign ($), percent sign (%), and plus sign (+), the characters will be converted to the following characters:

Characters before conversion Characters after conversion
/ $2f
$ $24
% $25
+ $2b

Example:
When the temporary directory for JSP is the default directory and the context root name is J2EE_AP1/WEB_AP1_war, the output destination for the JSP compilation results of the relevant Web applications will be as follows:
  • In Windows
    Cosminexus-installation-directory\CC\server\repository\server-name\web\J2EE_AP1$2fWEB_AP1_war
  • In UNIX
    /opt/Cosminexus/CC/server/repository/server-name/web/J2EE_AP1$2fWEB_AP1_war
(b) Configuration of output destination directory

The following figure shows the configuration of the output destination directory for JSP compilation results.

Figure 2-8 Configuration of output destination directory for JSP compilation results (When JSP pre-compilation is not executed)

[Figure]

The directory configuration is explained below: