Facts, hacks and attacks from my life as a web application developer
HiI used the same code and it is not able to find the ServletContainer class. I am using JBoss 5.X and I do not think it comes with this container.Error is :--com.sun.jersey.spi.service.ServiceConfigurationError: com.sun.jersey.spi.HeaderDelegateProvider: The class com.sun.jersey.core.impl.provider.header.LocaleProvider implementing provider interface com.sun.jersey.spi.HeaderDelegateProvider could not be instantiated: null
Dear Chase,these seem to be the same steps as writing a RESTful web service in Glassfish. The big difference is that Glassfish comes with all Jersey JARs installed. My question is, which JARs did you deploy into which JBoss directory?
Typically, you would either put JARs into jboss/servers/XXX/lib, where XXX is your server name, or you would have them packaged in your JARs.Which JARs you need will likely be different depending on your configuration. I would start by including jersey.jar itself, the trouble-shooting via the JBOSS logs.
Hi Chase,your jersey example is running well on JBoss 4.2.3, but on JBoss 5.1.0 I get this:java.lang.ClassCastException: com.sun.xml.bind.v2.runtime.JAXBContextImpl cannot be cast to javax.xml.bind.JAXBContextAny idea, what can I do?
I deployed jersey on jboss 5.1 following the tutorial. The libraries I add wereactivation-1.1.jarasm-3.1.jarjersey-bundle-1.8.jarstax-api-1.0-2.jarI had a similar problem to Snooker and took out the jaxb jars that come from jersey from my project lib as I am running under JRE 6. JAXB is included with Java 6 so did not need to add it to the project.
hi, i can confirm with these libraries it works under jboss5.1activation-1.1.jarasm-3.1.jarjaxb-api-2.1.jarjaxb-impl-2.1.jarjersey-bundle-1.5.jarjersey-core-1.5.jarjersey-server-1.5.jarjsr311-api-1.0.jarstax-api-1.0-2.jar
thanks for this simple but very helpful tutorial.. helped me very much !