Integration

Provides information how to integrate the smartics-properties extension into a JBoss application server and use it with a deployable.

Add Path to Modules Folder

First add the generated module folder to your JBoss installation by editing the bin/{standalone|domain}.{bat|sh}:

set  "JBOSS_MODULEPATH=%JBOSS_HOME%\modules"
set  "JBOSS_MODULEPATH=%JBOSS_MODULEPATH%;my-path-to.jboss-modules"

Register Extension

Add the extension to the extensions element within your configuration file (e.g. standalone.xml):

<extension module="de.smartics.properties.extension"/>

Register Subsystem

For the extension register a subsystem with the configuration according to your environment:

<subsystem xmlns="urn:de.smartics:properties:1.0">
    <configurations>
        <configuration name="my-configuration-name">
          ...
        </configuration>
    </configurations>
</subsystem>

Add Dependency to Deployable

In order to access the extension from your deployable, add the following deployment structure XML (WEB-INF/jboss-deployment-structure.xml):

<jboss-deployment-structure xmlns="urn:jboss:deployment-structure:1.1">
  <deployment>
    <dependencies>
      <module
        name="de.smartics.properties.extension"
        slot="main"
        export="true"
        annotations="true">
        <imports>
          <include path="META-INF/"/>
        </imports>
      </module>
    </dependencies>
  </deployment>
</jboss-deployment-structure>

Add Dependency to Configuration

To reference a configuration of the extension, add the following to META-INF/smartics-properties/boot.properties:

smartics.properties.bootConfigurationName=my-configuration-name

We reference the sample configuration named my-configuration-name provided above.

What's next?

Now you are ready configure the subsystem.