I'm using CXF 3.1.7 to create a JAXRS service that uses <jaxrs:server> with no custom providers. I'm trying to send a stream of data back in the http response using content-type application/custom+xml. The http response entity is set to an instance of a class that implements javax.ws.core.StreamingOutput. When requesting this resource, I get a http 500 error that states "JAXBException occured: class com.MyStreamingOutput nor any of its super class is known to this context.
I stepped thru CXF source code via remote debugger and see that the JAXBElementProvider is being chosen, likely because of content-type application/custom+xml. If I change my http response to use content-type application/customXml, the BinaryDataProvider is used and the response body is what is desired. However, I need to return content-type application/custom+xml. What is the best way to configure <jaxrs:server> so that content-type application/custom+xml can be returned using a http entity that implements javax.ws.core.StreamingOutput? I prefer not to use JAXB as I know the XML is valid/well-formed. -- Sent from: http://cxf.547215.n5.nabble.com/cxf-user-f547216.html
