WHy I get "Only one JAX-RS Application Class allowed.." on JBoss 6 final?
gfzhang Jan 11, 2011 6:08 AMI deployed a sample war of Atmosphere ( a comet framework) on JBoss 6 final, but I got:
2011-01-10 16:45:11,328 ERROR[ProfileServiceBootstrap] (Thread-2) Failed to load profile::org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incompletedeployments (SEE PREVIOUS ERRORS FOR DETAILS):
DEPLOYMENTS IN ERROR:
Deployment"vfs:///D:/projects/samples/jboss-6.0.0.Final/server/default/deploy/jquery-pubsub.war"is in error due to the following reason(s): org.jboss.deployers.spi.DeploymentException:Only one JAX-RS Application Class allowed.com.sun.jersey.api.core.WebAppResourceConfigcom.sun.jersey.api.core.ApplicationAdaptercom.sun.jersey.api.core.ScanningResourceConfigcom.sun.jersey.api.core.ResourceConfig com.sun.jersey.server.impl.application.DeferredResourceConfigcom.sun.jersey.api.core.ClasspathResourceConfigcom.sun.jersey.api.core.DefaultResourceConfigcom.sun.jersey.api.core.PackagesResourceConfigcom.sun.jersey.api.core.ClassNamesResourceConfig
at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:1228)[:2.2.0.GA]
atorg.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:905)[:2.2.0.GA]
at org.jboss.system.server.profileservice.deployers.MainDeployerPlugin.checkComplete(MainDeployerPlugin.java:87)[:6.0.0.Final]
atorg.jboss.profileservice.deployment.ProfileDeployerPluginRegistry.checkAllComplete(ProfileDeployerPluginRegistry.java:107)[:0.2.2]
at org.jboss.system.server.profileservice.bootstrap.BasicProfileServiceBootstrap.start(BasicProfileServiceBootstrap.java:135)[:6.0.0.Final]
atorg.jboss.system.server.profileservice.bootstrap.BasicProfileServiceBootstrap.start(BasicProfileServiceBootstrap.java:56)[:6.0.0.Final]
atorg.jboss.bootstrap.impl.base.server.AbstractServer.startBootstraps(AbstractServer.java:827)[jboss-bootstrap-impl-base.jar:2.1.0-alpha-5]
atorg.jboss.bootstrap.impl.base.server.AbstractServer$StartServerTask.run(AbstractServer.java:417)[jboss-bootstrap-impl-base.jar:2.1.0-alpha-5]
at java.lang.Thread.run(Thread.java:619) [:1.6.0_21]
2011-01-10 16:45:11,359 INFO [org.apache.coyote.http11.Http11Protocol] (Thread-2) Starting Coyote HTTP/1.1on http-127.0.0.1-8080
2011-01-10 16:45:11,359 INFO [org.apache.coyote.ajp.AjpProtocol] (Thread-2) Starting Coyote AJP/1.3 onajp-127.0.0.1-8009
2011-01-10 16:45:11,390 INFO [org.jboss.bootstrap.impl.base.server.AbstractServer] (Thread-2) JBossAS[6.0.0.Final "Neo"] Started in 43s:687ms
I do not understand "Only one JAX-RS Application Class allowed.....".
Does JBoss 6 final package Jersey in the download? How to solve it?
I just download the zip, unzip it, deploy my war, then launch the JBoss.
Thanks for your help.