The following figure shows the default class loader configuration after a new installation.
Figure B-1 Default class loader configuration
![[Figure]](figure/zu0b0100.gif)
The contents of the class loaders are as follows:
- System class loader
The system class loader loads the classes provided by the Cosminexus components.
- Generation time: When a J2EE server starts
- Destruction time: When a J2EE server stops
- Connector class loader
The connector class loader loads the classes included in an individually deployed resource adapter. Only one connector class loader exists in the J2EE server.
- Generation time: When a J2EE server starts
- Destruction time: When a J2EE server stops
- JavaBeans class loader
The JavaBeans class loader loads the classes of the JavaBeans resources.
- Generation time: When a J2EE server starts
- Destruction time: When a J2EE server stops
- Application class loader
The application class loader loads the classes included in the EJB-JAR, library JAR, and resource adapters existing in the application. There is an application class loader for each application. The class name is com.hitachi.software.ejb.server.ApplicationClassLoader.
- Generation time: When a J2EE application starts
KDJE42143-I is output to cjmessage?.log (J2EE server operation log) (? indicates the number of log files).
- Destruction time: When a J2EE application stops
KDJE42144-I is output to cjmessage?.log (J2EE server operation log) (? indicates the number of log files).
- Web Application class loader
The Web application class loader loads the classes included in a WAR file within a J2EE application. There is a Web application class loader for each WAR file. The class name is org.apache.catalina.loader.WebappClassLoader.
- Generation time: When a J2EE application starts (When a Web application starts)
KDJE39219-I is output to cjmessage?.log (J2EE server operation log) (? indicates the number of log files).
- Destruction time: When a J2EE application stops (When a Web application stops)
KDJE39220-I is output to cjmessage?.log (J2EE server operation log) (? indicates the number of log files).
- JSP class loader
The JSP class loader loads the classes generated when the JSP files and tag files are compiled. There is a JSP class loader for each JSP.
- Generation time: When a JSP class is loaded
- Destruction time: When a J2EE application stops (When a Web application stops)
- Hint
- Loading a resource adapter
- A resource adapter deployed as a J2EE resource adapter is loaded using the connector class loader. A resource adapter that is included and used in a J2EE application is loaded using the application class loader.
- Note
- Destruction of the class loaders
- After stopping a J2EE application, when you execute the finalize processing# (processing of the finalize method) of the Web application class loader or application class loader, the KDJE39220-I or KDJE42144-I message is output.
- When a full garbage collection occurs after this message is output, the class loader and application are released from the heap.
- #: The finalize processing is executed with a thread dedicated to finalize processing (finalizer thread). One finalizer thread always exists for JavaVM execution. The thread operates in parallel with the other Java threads and processes the finalize() methods of the objects one by one.
- If the KDJE39220-I or KDJE42144-I message is not output, the possible causes are as follows:
- Cause
- (C-1): There is a software reference to an application class loader or application.
- (C-2): An object allocated to the Explicit heap is referencing an application class loader or application.
- For causes (C-1) and (C-2), implement the following systematic elimination of the causes (I-1) and (I-2) respectively, and check if the message is output:
- Systematic elimination of the causes
- (I-1): Specify -XX:SoftRefLRUPolicyMSPerMB=0 and execute the operation.
- For details on the SoftRefLRUPolicyMSPerMB option, see 7.8 Estimating the memory size of the Permanent area in the Java heap in the uCosminexus Application Server System Design Guide.
- (I-2): If the Explicit Memory Management functionality is enabled, disable the Explicit Memory Management functionality (-XX:-HitachiUseExplicitMemory).
- For details on the Explicit Memory Management functionality, see 16.2 Details of the extended JavaVM options in the uCosminexus Application Server Definition Reference Guide.
- If causes (C-1) and (C-2) are not applicable and if the KDJE39220-I or KDJE42144-I message is not output, even if the application is started or stopped repeatedly, a memory leak might have occurred.