You can set values that control the class-loading behavior of an installed enterprise application. Class loaders enable an application to access repositories of available classes and resources.
This article assumes that you have installed
an application on an application server.
Configure the class loaders of an enterprise application to set class-loader policy and mode values for this application.
An application class loader groups enterprise bean (EJB) modules, shared libraries, resource adapter archives (RAR files), and dependency Java archive (JAR) files associated to an application. Dependency JAR files are JAR files that contain code which can be used by both enterprise beans and servlets.
An application class loader is the parent of a Web application archive (WAR) class loader. By default, a Web module has its own WAR class loader to load the contents of the Web module. The WAR class-loader policy value of an application class loader determines whether the WAR class loader or the application class loader is used to load the contents of the Web module.
Use the administrative console to configure the class loaders.
Option | Description |
Parent First | Causes the class loader to search in the parent class loader first to load a class. This value is the standard for Development Kit class loaders and WebSphere Application Server class loaders. |
Parent Last | Causes the class loader to search in the application class loader first to load a class. By specifying Parent Last, your application can override classes contained in the parent class loader. Tip: Specifying the Parent Last value might result in LinkageErrors or ClassCastException messages if you have mixed use of overridden classes and non-overridden classes. |
Option | Description |
Module | Uses a different class loader for each WAR file. |
Application | Uses a single class loader to load all of the WAR files in your application. |
To enable reloading, specify an integer value that is greater than zero (for example, 1 to 2147483647).
To disable reloading, specify zero (0).
Related concepts
Class loaders
Related tasks
Class loading
Related reference
Enterprise application settings