3.5. Exclude a Subsystem from a Deployment

download PDF

This topic covers the steps required to exclude a subsystem from a deployment. This is done by editing the jboss-deployment-structure.xml configuration file. Excluding a subsystem provides the same effect as removing the subsystem, but it applies only to a single deployment.

Procedure 3.6. Exclude a Subsystem

  1. Open the jboss-deployment-structure.xml file in a text editor.
  2. Add the following XML inside the <deployment> tags:
      <subsystem name="SUBSYSTEM_NAME" />
  3. Save the jboss-deployment-structure.xml file.

The subsystem has been successfully excluded. The subsystem's deployment unit processors will no longer run on the deployment.

Example 3.6. Example jboss-deployment-structure.xml file.

<jboss-deployment-structure xmlns="urn:jboss:deployment-structure:1.2">
      <subsystem name="jaxrs" />
      <module name="org.javassist" />
      <module name="deployment.javassist.proxy" />
      <module name="deployment.myjavassist" />
      <module name="myservicemodule" services="import"/>
      <resource-root path="my-library.jar" />
  <sub-deployment name="myapp.war">
      <module name="deployment.myear.ear.myejbjar.jar" />
    <local-last value="true" />
  <module name="deployment.myjavassist" >
     <resource-root path="javassist.jar" >
         <exclude path="javassist/util/proxy" />
  <module name="deployment.javassist.proxy" >
      <module name="org.javassist" >
          <include path="javassist/util/proxy" />
          <exclude path="/**" />
Red Hat logoGithubRedditYoutubeTwitter


Try, buy, & sell


About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

© 2024 Red Hat, Inc.