0 Replies Latest reply on Sep 29, 2014 9:19 AM by Nicolas Zozol

    RestEasy with Spring MVC

    Nicolas Zozol Newbie

      I'm sharing an application (just a demo) with jax-Rs and Spring MVC

       

      Jax-RS is configured with

      @ApplicationPath("/api/*")

      and Spring uses web.xml :

       

      <servlet>

              <servlet-name>appServlet</servlet-name>

              <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>

              <init-param>

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

                  <param-value>/WEB-INF/spring/appServlet/servlet-context.xml</param-value>

              </init-param>

              <load-on-startup>1</load-on-startup>

          </servlet>

          <servlet-mapping>

              <servlet-name>appServlet</servlet-name>

              <url-pattern>/spring/*</url-pattern>

          </servlet-mapping>

       

      All JaxRS request goes to /api, when spring take /spring/*

      It works perfectly with Glassfish, but JBoss AS 7.1 tells me 404 on every JaxRS requests, when Spring works also.

       

      I've read on the RestEasy documentation that there is a kind of Spring integration :

       

      <listener> <listener-class> org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap </listener-class> </listener>

       

      Do we need that even in a JEE container ? thank you.