resteasyjboss6.xjboss-modules

What is the correct JBoss module dependency to reference org.jboss.resteasy in a static module?


I am attempting to deploy a static module that uses resteasy, which comes pre-installed as a system module:

[me@localhost:3 modules]$ ls -l system/layers/base/org/jboss/resteasy/resteasy-jaxrs/main/
total 660K
-rw-r--r-- 1 coer2 admin 7.7K Jun  2  2017 async-http-servlet-3.0-2.3.10.Final-redhat-1.jar
-rw-r--r-- 1 coer2 admin 2.1K Mar 27  2015 module.xml
-rw-r--r-- 1 coer2 admin 646K Jun  2  2017 resteasy-jaxrs-2.3.10.Final-redhat-1.jar

however my attempts to reference it are failing. My module looks like:

<?xml version="1.0" ?>

<resources>
    <resource-root path="."/>
    <resource-root path="JWTAUTHENTICATOR-SNAPSHOT.jar"/>
</resources>

<dependencies>
    <module name="org.jboss.resteasy-jaxrs"/>
    <module name="javax.servlet.api"/>
    <module name="javax.security.jacc.api"/>
    <module name="org.jboss.logging"/>
    <module name="org.picketbox"/>
    <module name="org.picketlink.federation"/>
    <module name="org.picketlink.federation.bindings"/>
    <module name="javax.api"/>
    <module name="javax.persistence.api"/>
    <module name="javax.resource.api"/>
    <module name="javax.security.auth.message.api"/>
    <module name="javax.transaction.api"/>
    <module name="javax.xml.bind.api"/>
    <module name="javax.xml.stream.api"/>
    <module name="org.infinispan"/>
    <module name="org.jboss.as.web"/>
    <module name="org.slf4j"/>
</dependencies>

The following produces log output that looks like:

Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0 11:47:53,135 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-7) MSC000001: Failed to start service jboss.web.valve.JWTAUTHENTICATOR: org.jboss.msc.service.StartException in service jboss.web.valve.JWTAUTHENTICATOR: org.jboss.modules.ModuleNotFoundException: org.jboss.resteasy-jaxrs:main Caused by: org.jboss.modules.ModuleNotFoundException: org.jboss.resteasy-jaxrs:main

Table 3.1 in the module doc, indicates this config should be sufficient, but previous experience with static module dependencies leaves me not surprised that it doesn't.

I suspect that it's less about this specific module and maybe a missing dependency that resteasy needs. Unfortunately, jboss module docs are not forthcoming with this information. Would appreciate insight.

Thanks, Robin


Solution

  • Answer is that the package namespace maps to the directory structure, so the specific module to be added needs to be appended to the package namespace:

    <module name="org.jboss.resteasy.resteasy-jaxrs"/>