M B E A N C O N F I G U R A T I O N A N D D E P E N D E N C Y M A N A G E M E N T P A G E 1 0 8
MBean Class Dependency Management
JBoss manages the dependency between an mbean and its class. If you attempt to deploy an
mbean whose class is not loaded, the configuration information is put on a waiting list.
When the class becomes available due to some additional deployment, your mbean will be
deployed. If the class of an existing mbean is undeployed, the mbean will also be undeployed
and its last configuration put on the same waiting list, so if the class is redeployed the
mbean will be resurrected.
MBean MBean Dependency Management
JBoss manages dependencies between mbeans using the depends and depends list attribute
styles. An mbean will wait to progress through the create and start steps until all the
mbeans it depends on have been created and started. Similarly, stopping or destroying an
mbean will stop or destroy mbeans that depend on it. Circular dependencies are not
handled. You can use this to assure that mbeans are started in the correct order, even if
they are in separate configuration files deployed in the wrong order.
SAR file format and package nesting
* service.xml files may be deployed alone or packaged into a sar (service archive) file. In a
sar, the file must have the name jboss service.xml and be located in META INF (note case).
The sar file may also contain classes, jars, or any other deployable package such as ear, war,
rar, or (ejb) jar. In addition, all of these packages may include additional nested deployable
packages. These packages are deployed from inside (most deeply nested) out. Note that
most of these combinations are JBoss specific and not j2ee compliant. Generally, although
manifest classpath entries can be used, they are usually unnecesary in JBoss.
Classpath Element
The *service.xml file may also contain one or more classpath elements, of the form
. The codebase attribute indicates
where the packages are to be found, and the archives attributes contains a comma separated
list of packages to be deployed. JBoss will attempt to deploy these before processing the
mbean configurations. This dependency management can usually be left to the automatic
Mbean Class dependency management.
LocalDirectory Element
The *service.xml file may also contain one or more local directory elements, of the form
. This can only be used in a sar file. This will result in
whatever is located at some path within the sar being copied verbatim to the "db" directory
in your JBoss installation. If a file is already present, it is not overwritten and these files
108
footer
Our partners:
PHP: Hypertext Preprocessor Cheap Web Hosting
JSP Web Hosting
Ontario Web Hosting
Jsp Web Hosting
Cheapest Web Hosting
Java Hosting
Cheapest Hosting
Visionwebhosting.net Business web hosting division of Vision Web Hosting Inc.. All rights reserved