JBoss.org Community Documentation

4.2. Configuration

To configure your microcontainer the you can use the JBOSS_HOME/server/<server_configuration>/conf/bootstrap-beans.xml and JBOSS_HOME/server/<server_configuration>/conf/bootstrap-repo-beans.xml files where <server_configuration> represents the all , default or minimal JBoss AS configurations. The configuration files have comments to guide you on the specific configurations available as illustrated by the example below.

	<deployment xmlns="urn:jboss:bean-deployer:2.0">
		<!-- All beans use the bootstrap classloader -->
		<classloader><inject bean="BootstrapClassLoader"/></classloader>
		<!-- TODO Should split this file up and use the new classloader -->
		<bean name="BootstrapClassLoader" class="org.jboss.system.NoAnnotationURLClassLoader">
			<constructor factoryClass="org.jboss.system.NoAnnotationURLClassLoader" factoryMethod="createClassLoader">
<bean name="ProfileServiceBootstrap" class="org.jboss.system.server.profileservice.ProfileServiceBootstrap">
<property name="kernel"><inject bean="jboss.kernel:service=Kernel"/></property>

<!-- The legacy JMX kernel -->
<bean name="JMXKernel" class="org.jboss.system.server.jmx.JMXKernel">
<property name="kernel"><inject bean="jboss.kernel:service=Kernel"/></property>
	<property name="serverImpl"><inject bean="JBossServer"/></property>
	<property name="oldClassLoader">false</property>
....(content truncated)

	<!-- The ManagedDeploymentCreator implementation -->
	<bean name="ManagedDeploymentCreator" 	class="org.jboss.deployers.plugins.managed.DefaultManagedDeploymentCreator" />
	<!-- The holder for deployers that determine structure -->
	<bean name="StructuralDeployers" 		class="org.jboss.deployers.vfs.plugins.structure.VFSStructuralDeployersImpl">
		<property name="structureBuilder">
		<!-- The consolidator of the structure information -->
		<bean name="StructureBuilder" 		class="org.jboss.deployers.vfs.plugins.structure.VFSStructureBuilder"/>
	<!-- Accept any implementor of structure deployer -->
	<incallback method="addDeployer"/>
	<uncallback method="removeDeployer"/>
...(content truncated)

The main beans are:

  • ProfileService : this bean loads the deployments associated with the named server profile, "default", "all" or whatever name is passed in as the "-c" option to the server. Its an extension of the jboss-4.0.x and earlier notion of always looking to the filesystem server/name/conf/jboss-service.xml and server/name/deploy to load deployments.

  • AspectManager? : the AOP aspects

  • MainDeployer : this bean is an update of the JMX based MainDeployer from earlier versions to a one based on the Microcontainer, JBoss5VirtualFileSystem, and Virtual Deployment Framework(VDF). Deployer aspects are registered with the MainDeployer as an ordered list via inject of the deployers property.

  • ServiceClassLoaderDeployer? : this bean manages the class loading aspect of deployment.

  • JARDeployer : this bean is a structural deployment aspect which handles the legacy nested deployment behavior of adding non-deployable jars to the current deployment classpath.

  • FileStructure? : this bean is a structural deployment aspect which recognizes well know deployment file types specified by suffix.

  • AspectDeployer? : handles aop descriptor deployments.

  • BeanDeployer? : this bean translates deployer-beans.xml into KernelDeployment? for the descriptor beans.

  • KernelDeploymentDeployer? : translates a KernelDeployment? into the constituent BeanMetaData instances for the kernel beans.

  • BeanMetaDataDeployer? : creates the kernel beans from the deployment BeanMetaData.

  • SARDeployer : this bean is a port of the legacy JMX SARDeployer to the VDF. It handles the legacy jboss-service.xml style of mbean deployment descriptors and maps this into a ServiceDeployment? pojo.

  • ServiceDeploymentDeployer? : translates ServiceDeployment? pojo into the constituent ServiceMetaData that represent the various mbeans.

  • ServiceDeployer? : creates the mbean services from deployment ServiceMetaData instances.

  • JMXKernel : this bean manages the instantiation of a JMX kernel and MBeanServer in the jboss domain. It is used by the SARDeployer. It will be used by other management deployment aspects in the future to expose kernel beans via JMX.

  • VFSDeployerScanner? : a scanner bean that loads the deployers directory contents into the basic profile service.

  • VFSDeploymentScanner? : a scanner bean that loads the deploy directory contents into the basic profile service.

  • HDScanner : a bean that queries the profile service for changes in deploy directory contents and redeploys updated content, undeploys removed content, and add new deployment content to the profile service.