Hi
On 14/01/14 11:34, rpd wrote:
Hi,
Thanks a lot for the reply. We are using the non Spring Servlet. Presumably,
then, in web.xml I would need only to include the entry...
<init-param>
<param-name>jaxrs.properties</param-name>
<param-value>
serializeAsArray=true
</param-value>
</init-param>
Is that it?
No, the above would set the endpoint properties, JSONProvider does not
check them, one can do it like this:
<init-param>
<param-name>jaxrs.providers</param-name>
<param-value>
org.apache.cxf.systest.jaxrs.BookStoreProvider1
org.apache.cxf.systest.jaxrs.BookStoreProvider2(a=b c=d)
</param-value>
</init-param>
In this case though it won't help actually, it is only possible to
inject simple non-collection properties and the arrayKeys JSONProvider
property is a list. I can see it can be supported easily enough too, but
not at the moment.
The only way then for now is to register a custom JAX-RS Application
when you can directly configure the provider
Cheers, Sergey
Rob
________________________________
From: Sergey Beryozkin [via CXF] <ml-node+s547215n5738478...@n5.nabble.com>
To: rpd <robpodol...@yahoo.co.uk>
Sent: Sunday, 12 January 2014, 18:24
Subject: Re: NON-SPRING JSON array serialization workaround please??
Hi
You can use CXFNonSpringJaxrsServlet where JSONProvider is configured
via either custom JAX-RS Application or declaratively, see
http://cxf.apache.org/docs/jaxrs-services-configuration.html#JAXRSServicesConfiguration-ConfiguringJAX-RSservicesincontainerwithoutSpring
Cheers, Sergey
On 10/01/14 12:11, rpd wrote:
________________________________