Hi Daniel

Please see "Registering custom JAXRS providers" in [1].
There's a couple of options. One is to to use an "org.apache.cxf.rs.provider" property which accepts a list of class names, so you can list the provider you need, ex, "org.apache.cxf.jaxrs.provider.JSONProvider", etc. The other option is to register an instance of say JSONProvider as an OSGI service, this option is the only way at the moment to have a provider instance configured with some custom properties...

To simplify things a bit, I'll probably need to intoduce "json", "atom", "xbeans", etc for org.apache.cxf.rs.databinding so that users can avoid having to specify classnames like "org.apache.cxf.jaxrs.provider.JSONProvider" directly...For more advanced cases we will need to recognize providers configured in Spring (as an alternative to registering them as OSGI services)...

cheers, Sergey



[1] http://cxf.apache.org/distributed-osgi-reference.html#DistributedOSGiReference-ServiceProviderpropertiesForConfiguringRESTfulJAXRSbasedendpointsandconsumers

----- Original Message ----- From: "Daniel Bimschas" <[email protected]>
To: <[email protected]>
Sent: Tuesday, January 26, 2010 9:59 PM
Subject: DOSGi and JSON responses


Hi List!

I've now successfully developed a project that additionally exposes its interfaces over the DOSGi based JAX-RS implementation as RESTful service. Therefore I've used the JAXB-Binding which worked fine. However, I couldn't find any information about how to get the JSON responses working (they are always empty, i.e. 0 bytes of payload). Can somebody help me here and point me to the right documentation?

Kind regards,
Daniel=

Reply via email to