3

I want to exclude all automatic dependencies in JBoss 7. Was not able to find the answer here: https://docs.jboss.org/author/display/AS7/Class+Loading+in+AS7

Added

Automatic (implicit) dependencies are described here:

https://docs.jboss.org/author/display/AS7/Implicit+module+dependencies+for+deployments

Now I need to do it explicitly. See below.

<jboss-deployment-structure>
    <deployment>
        <dependencies>
            <module name="org.jboss.as.jmx"/>
        </dependencies>

        <exclusions>
            <module name="javaee.api" />
            <module name="javax.xml.bind.api" />
            <module name="javax.persistence.api" />
            ...
        </exclusions>
    </deployment>
</jboss-deployment-structure>

Question if I can do it using simple configuration like:

<jboss-deployment-structure>
    <deployment>
        <dependencies>
            <module name="org.jboss.as.jmx"/>
        </dependencies>

        <exclusions>
            <subsystem name="implicit" />
        </exclusions>
    </deployment>
</jboss-deployment-structure>
4

1 回答 1

2

我不认为你可以。但是,无论如何,这没有任何意义,例如 JDK 是那些隐式依赖项的一部分——你真的不想用你的应用程序部署整个 JDK,是吗?

创建一组您不想要的隐式依赖项,并像您所做的那样将它们放入 jboss-deployment-structure 中。

于 2013-09-10T05:14:03.740 回答