Details
Description
In my spring xml If I use ContentTypeOutInterceptor with following syntax
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
<jaxrs:server ...>
...
<jaxrs:inInterceptors>
<bean class="org.apache.cxf.binding.http.interceptor.ContentTypeOutInterceptor"/>
</jaxrs:inInterceptors>
...
</jaxrs:server
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Then that results into ClassCastException. The Exception is thrown by following code from serializeMessage method of JAXRSOutInterceptor.java
>>>>>>>>>>>>>>>>>>>>>>>>>>>>
MultivaluedMap<String, Object> responseHeaders =
(MultivaluedMap)message.get(Message.PROTOCOL_HEADERS);
<<<<<<<<<<<<<<<<<<<<<<<<<<<<
It seems the ContentTypeOutInterceptor uses HashMap object to store Message.PROTOCOL_HEADERS value, but JAXRSOutInterceptor expects MultivaluedMap.
My feeling is we should fix ContentTypeOutInterceptor. But as I am new to CXF, I am filing a bug.