Hi All,
I'm trying to build a basic jax-rs example using version 2.7.11. Using the
server and service code from the example code
<http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/jax_rs/basic/>,
I can build and run it just like the readme instructions say (mvn -Pserver)
but if I produce a jar bundled with the dependencies and run from the
command line I cannot get the server to start. I get the following
exception
test-service/target$ java -cp test-service-1.0-jar-with-dependencies.jar
com.test.Server
Exception in thread "main"
org.apache.cxf.service.factory.ServiceConstructionException
at
org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java:190)
at com.test.Server.<init>(Server.java:24)
at com.test.Server.main(Server.java:29)
Caused by: org.apache.cxf.BusException: No DestinationFactory was found for
the namespace http://cxf.apache.org/transports/http.
at
org.apache.cxf.bus.managers.DestinationFactoryManagerImpl.getDestinationFactory(DestinationFactoryManagerImpl.java:130)
at org.apache.cxf.endpoint.ServerImpl.initDestination(ServerImpl.java:78)
at org.apache.cxf.endpoint.ServerImpl.<init>(ServerImpl.java:62)
at
org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java:151)
... 2 more
Can anyone point me in the right direction?
Thanks,
Chris
I'm trying to build a basic jax-rs example using version 2.7.11. Using the
server and service code from the example code
<http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/jax_rs/basic/>,
I can build and run it just like the readme instructions say (mvn -Pserver)
but if I produce a jar bundled with the dependencies and run from the
command line I cannot get the server to start. I get the following
exception
test-service/target$ java -cp test-service-1.0-jar-with-dependencies.jar
com.test.Server
Exception in thread "main"
org.apache.cxf.service.factory.ServiceConstructionException
at
org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java:190)
at com.test.Server.<init>(Server.java:24)
at com.test.Server.main(Server.java:29)
Caused by: org.apache.cxf.BusException: No DestinationFactory was found for
the namespace http://cxf.apache.org/transports/http.
at
org.apache.cxf.bus.managers.DestinationFactoryManagerImpl.getDestinationFactory(DestinationFactoryManagerImpl.java:130)
at org.apache.cxf.endpoint.ServerImpl.initDestination(ServerImpl.java:78)
at org.apache.cxf.endpoint.ServerImpl.<init>(ServerImpl.java:62)
at
org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java:151)
... 2 more
Can anyone point me in the right direction?
Thanks,
Chris