Hi
On 26/09/13 19:01, Aaron Titus wrote:
Hello All, I have a question that I have been unable to answer looking through google and stackoverflow. I am using Apache CXF 2.7.6, and also Jackson 1.9 configured as the provideer for Jaxb to JSON mapping. It works except dates are serialized as long numbers. I found instructions online on how to configure this in the cxf-servlet.xml file, by setting the serializationConfig.dateFormat property. However this apparently only applies to older Jackson versions, as it does not work with 1.9. There are plenty of examples of how to do this in plain code, however I need to know how to do it in the configuration file so that CXF will create the provider instance with the correct configuration. Can anyone point me in the right direction? Thanks in advance!
The simplest option to do without Spring is to create a custom JAX-RS Application, initialize your Jackson provider instance as needed and return in Application getSingletons method, then register your Application class, you will find an example of how to register in this section:
http://cxf.apache.org/docs/jaxrs-services-configuration.html#JAXRSServicesConfiguration-ConfiguringJAXRSservicesincontainerwithoutSpring Sergey
Aaron
-- Sergey Beryozkin Talend Community Coders http://coders.talend.com/ Blog: http://sberyozkin.blogspot.com
