See
https://github.com/apache/cxf/blob/master/osgi/karaf/features/src/main/resources/features.xml#L20
I believe it is a boot time feature.
Sergey
On 03/09/15 11:37, Benson Margulies wrote:
That's true, I'm not. Or, to be exact, I bet it's in the container,
but I don't declare it as the dependency on my POM. What does it to do
arrange this?
On Thu, Sep 3, 2015 at 5:09 AM, Sergey Beryozkin <[email protected]> wrote:
Hi
Indeed.
FYI, it should be possible not to install it starting from CXF 3.1.2, but
only if the application code does not use Response or other static utility
methods like MediaType.valueOf() which rely on RuntimeDelegate.
Example if one has ContainerResponseFilter then all the response headers can
be set there, etc.
I guess it does not make much sense to rewrite the code just to avoid
installing a service mix bundle :-), but just mentioning here that the
option exists...
Sergey
On 03/09/15 07:06, Aki Yoshida wrote:
it looks like you are not using servicemix's jaxrs api bundle?
2015-09-03 3:18 GMT+02:00 Benson Margulies <[email protected]>:
javax.ws.rs.ext.RuntimeDelegate=org.apache.cxf.jaxrs.impl.RuntimeDelegateImpl
as a system property fixed this, but why did I need to add it?
On Wed, Sep 2, 2015 at 9:04 PM, Benson Margulies <[email protected]>
wrote:
Oh, arg, I was wrong. It's still broken, even with the service
description bundle in the dependencies.
On Wed, Sep 2, 2015 at 8:55 PM, Benson Margulies <[email protected]>
wrote:
I found my own oversight.
I had split off some utilities, and the utility bundle did not do:
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-rs-service-description</artifactId>
<version>${cxf-version}</version>
</dependency>
On Wed, Sep 2, 2015 at 8:16 PM, Benson Margulies <[email protected]>
wrote:
I built a simple prototype of a CXF JAX-RS web service with CXF 3.1.1
and Karaf 4.0.1 that worked great. So I moved on to flesh it out to
make a real application.
I think that I'm installing just the same features into Karaf, but as
soon as I try to return a response, I'm rewarded with the backtrace
below. Clearly I've got something confused, but, what?
ava.lang.RuntimeException: java.lang.ClassNotFoundException:
org.glassfish.jersey.internal.RuntimeDelegateImpl not found by
javax.ws.rs-api [46]
at
javax.ws.rs.ext.RuntimeDelegate.findDelegate(RuntimeDelegate.java:152)
at
javax.ws.rs.ext.RuntimeDelegate.getInstance(RuntimeDelegate.java:120)
at
javax.ws.rs.core.Response$ResponseBuilder.newInstance(Response.java:848)
at javax.ws.rs.core.Response.status(Response.java:590)
at javax.ws.rs.core.Response.status(Response.java:601)
at javax.ws.rs.core.Response.ok(Response.java:622)
at
com.basistech.ws.frontend.util.JsonResponseUtils.returnJsonResponse(JsonResponseUtils.java:59)
at
com.basistech.ws.frontend.service.RaasRsPingService.ping(RaasRsPingService.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)[:1.8.0_05]
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[:1.8.0_05]
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.8.0_05]
at java.lang.reflect.Method.invoke(Method.java:483)[:1.8.0_05]
at
org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInvoker.java:180)[75:org.apache.cxf.cxf-core:3.1.1]
at
org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:96)[75:org.apache.cxf.cxf-core:3.1.1]
at
org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:200)[88:org.apache.cxf.cxf-rt-frontend-jaxrs:3.1.1]
--
Sergey Beryozkin
Talend Community Coders
http://coders.talend.com/