Ok, #1: Make your resteasy-jaxrs dependency scoped provided in your pom.xml. Resteasy is already included in AS7. People have also been reporting problems when the duplicate resteasy jars have been included in their WARs.
#2: Make your web.xml empty: <web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" version="3.0"> </web-app> AS7 will automatically register the correct Resteasy filter/servlets. Let me know if that fixes things. On 2/19/12 10:34 AM, Martin Hynar wrote: > Hi, > > I setup an RestEasy (2.3.1.GA <http://2.3.1.GA>) app that used > ResteasyBootstrap listener to load my JAXS resources automatically when > war is deployed. However, after war was loaded by server (JBoss AS > 7.1.0) the URI of the service is not available. There is no information > that any of the JAX-RS resources was loaded. > > When I tried to add resteasy.scan context parameter, the log said that > 1. this parameter is not necessary and will be ignored because runtime > shall scan for resources anyway 2. container threw exceptions > complaining that public constructor for > org.jboss.resteasy.core.AsynchronousDispatcher does not exist. > > 16:24:58,234 WARN [org.jboss.jaxrs] (MSC service thread 1-3) > JBAS011204: resteasy.scan found and ignored in web.xml. This is not > necessary, as Resteasy will use the container integration in the JAX-RS > 1.1 specification in section 2.3.2 > 16:24:58,265 ERROR > [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/rest]] > (MSC service thread 1-4) Exception sending context initialized event to > listener instance of class > org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap: > java.lang.RuntimeException: Unable to find a public constructor for > class org.jboss.resteasy.core.AsynchronousDispatcher > > Also, I tried to deploy the application to JBoss AS 6.1.0 and > - with the reseasy.scan parameter it worked fine - everything deployed, > service available > - without that parameter the URI was not available > > You can check the application in the attached archive. Just build it > with Maven. The URI that shall provide service is the > http://localhost:8080/rest/service/s > > br, Martin > > > ------------------------------------------------------------------------------ > Virtualization& Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > > > > _______________________________________________ > Resteasy-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/resteasy-users -- Bill Burke JBoss, a division of Red Hat http://bill.burkecentral.com ------------------------------------------------------------------------------ Virtualization & Cloud Management Using Capacity Planning Cloud computing makes use of virtualization - but cloud computing also focuses on allowing computing to be delivered as a service. http://www.accelacomm.com/jaw/sfnl/114/51521223/ _______________________________________________ Resteasy-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/resteasy-users
