0 Replies Latest reply on May 14, 2014 12:05 PM by raghu n m

    Jersey 2 and Jboss EAP 6.2 error: javax.ws.rs.core.Application.getProperties()Ljava/util/Map;

    raghu n m Newbie

      To recreate this problem,

      step 1: Download JBoss EAP 6.2  - build from AS 7.3 and start the server

      step 2: Compile and deploy the attached source code. NOTE: This example is copied from jersey2 examples git.

       

      I am trying to develop jersey 2 application in Jboss EAP 6.2. Please find the attached code. I have used below context param in web.xml and removed subsystems using jboss-deployment-structure.xml. I am getting error java.lang.NoSuchMethodError: javax.ws.rs.core.Application.getProperties()Ljava/util/Map; I did some research and removed module "org.jboss.resteasy.resteasy-jaxrs" from folder jboss-eap-6.2/modules/system/layers/base/javax/ws/rs. Then it worked fine. This kills JBoss rest easy functions. Is there any way we can do it inside my project.

       

      <context-param>

              <param-name>contextConfigLocation</param-name>

              <param-value>classpath:applicationContext.xml</param-value>

          </context-param>

          <context-param>

              <param-name>resteasy.scan</param-name>

              <param-value>false</param-value>

          </context-param>

          <context-param>

              <param-name>resteasy.scan.providers</param-name>

              <param-value>false</param-value>

          </context-param>

          <context-param>

              <param-name>resteasy.scan.resources</param-name>

              <param-value>false</param-value>

          </context-param>

       

      <exclude-subsystems>

                  <subsystem name="jaxrs" />

                  <subsystem name="resteasy" />

              </exclude-subsystems>

              <exclusions>

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

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

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

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

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

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

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

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

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

                  <module name="org.apache.log4j"/> 

                  <module name="javax.ws.rs.api"/>

              </exclusions>