The difference between the two is that the first has MTOM turned on the second does not. If you change the content-type, you would also need to modify the body of the message to remove the mtom wrapper.
The easiest thing to do is really just turn off MTOM for the service. In that case, it would always be text/xml. Dan On Saturday 19 June 2010 8:46:40 am Chris Hardin wrote: > I need some help. I need to adjust the header in the Soap response from > CXF. A consumer of my Web Service cannot read the response, but from > another server running another ESB, they can. The only different is the > Content-type. Can anyone tell me how I can configure the content-type that > is being sent??? > > I want to change > > *Content-Type: multipart/related; type="application/xop+xml"; > boundary="uuid:6168f1b2-b8ef-4365-b373-7658db001210"; start="<** > [email protected]* <[email protected]>*>"; > start-info="text/xml" > > to > > **Content-Type: text/xml; charset=UTF-8* > > Exception header, I can process it just fine: > > HTTP/1.1 500 Internal Server Error > Date: Wed, 02 Jun 2010 21:29:10 GMT > Server: IBM_HTTP_Server > Set-Cookie: JSESSIONID=0000pVTuCyt4c63GyVWq4euG9Xl:14trbiqga; Path=/ > Expires: Thu, 01 Dec 1994 16:00:00 GMT > Cache-Control: no-cache="set-cookie, set-cookie2" > Connection: close > Transfer-Encoding: chunked > *Content-Type: text/xml; charset=UTF-8 > *Content-Language: en > > > Good response that I can't read: > > HTTP/1.1 200 OK > Date: Wed, 02 Jun 2010 21:29:40 GMT > Server: IBM_HTTP_Server > Set-Cookie: JSESSIONID=0000BHspg59kUwvOwcIVJSNE2bD:14trbiqga; Path=/ > Expires: Thu, 01 Dec 1994 16:00:00 GMT > Cache-Control: no-cache="set-cookie, set-cookie2" > Transfer-Encoding: chunked > *Content-Type: multipart/related; type="application/xop+xml"; > boundary="uuid:6168f1b2-b8ef-4365-b373-7658db001210"; start="<** > [email protected]* <[email protected]>*>"; > start-info="text/xml" > *Content-Language: en -- Daniel Kulp [email protected] http://dankulp.com/blog
