Hi Sean,
You need to add your Application class as a web archive context param in
web.xml. For example:
<context-param>
<param-name>javax.ws.rs.core.Application</param-name>
<param-value>org.jboss.jbossts.rts.service.TMApplication</param-value>
</context-param>
The servlet class should reference Bills' implementation as in:
<servlet>
<servlet-name>Resteasy</servlet-name>
<servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher</servlet-class>
</servlet>
Mike
> Hello,
> I am new to using RESTEasy and am having trouble getting an example to work.
>
> When I build the war and deploy to JBOSS 6, I am getting the following
> error trace
>
> 11:09:29,148 ERROR [[/Chap3]] Exception starting filter Resteasy:
> java.lang.ClassCastException: ca.st.services.ShopApp cannot be cast to
> javax.ws.rs.core.Application
>
> The ShopApp Class extends javax.ws.rs.core.Application so i am not
> really sure what is going on.
>
> My snippet from the web.xml looks like the following.
>
> <servlet>
> <servlet-name>Rest</servlet-name>
> <servlet-class>
> ca.st.services.ShopApp
> </servlet-class>
> </servlet>
>
> Any ideas would be appreciated...
>
> Thanks
>
|