37 lines
2.7 KiB
HTML
37 lines
2.7 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<META http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<LINK rel="stylesheet" type="text/css" href="../../../rzahg/ic.css">
|
|
|
|
<title>Classloader hierarchy</title>
|
|
</head>
|
|
|
|
<BODY>
|
|
<!-- Java sync-link -->
|
|
<SCRIPT LANGUAGE="Javascript" SRC="../../../rzahg/synch.js" TYPE="text/javascript"></SCRIPT>
|
|
|
|
<h4><A NAME="clshier"></A>Classloader hierarchy</h4>
|
|
|
|
|
|
|
|
<p>The run time environment of WebSphere Application Server - Express uses these classloaders to find and load new classes for an application in this order:</p>
|
|
|
|
<ol>
|
|
<li><p><strong><a href="clsjvm.htm">Java Virtual Machine classloaders</a></strong>
|
|
<br>The Java Virtual Machine classloaders are provided by the Java runtime. JDK 1.3 provides 3 classloaders: boot classloader, extensions classloader and user classloader.</p></li>
|
|
<li><p><strong><a href="clsext.htm">WebSphere extensions classloader</a></strong>
|
|
<br>The WebSphere Application Server - Express run time is loaded by the WebSphere extensions classloader.</p></li>
|
|
<li><p><strong>Application classloaders</strong>
|
|
<br>To find and load classes for an application, WebSphere Application Server - Express for iSeries uses one or more application classloaders that load elements of enterprise applications running in the server.</p>
|
|
<p>The application elements can be Web modules, resource adapters, and dependency JAR files. Application classloaders follow J2EE class loading rules to load classes and JAR files from an enterprise application.</p></li>
|
|
</ol>
|
|
|
|
|
|
<p>Each classloader is a child of the classloader above it. That is, the application module classloaders are children of the WebSphere-specific extensions classloader, which is a child of the CLASSPATH Java classloader. Whenever a class needs to be loaded, delegation depends on the delegation mode setting, which always defaults to PARENT_FIRST, but can be changed to PARENT_LAST. If none of the parent classloaders can find the class, the original classloader attempts to load the class. Requests can only go to a parent classloader; they cannot go to a child classloader. For example, if a class in the WebSphere extension classloader tried to reference a class in an application classloader, it would not be found. After a class is loaded by a classloader, any new classes that it tries to load reuse the same classloader or go up the precedence list until the class is found.</p>
|
|
|
|
<p>The i5/OS Java Virtual Machine can run in two modes -- JIT (just in time compiler) and DE (direct execution). For more information on how these modes can be used by the different classloaders, see <strong><a href="clsjvamode.htm">Java execution modes</a></strong>.</p>
|
|
|
|
</body>
|
|
</html>
|