Hi again, Nobody has an idea for this problem ?
De : MARTELLI Julien Envoyé : vendredi 13 mai 2011 15:21 À : [email protected] Objet : Splitted server response Hi folks, I recently developed a custom input interceptor for one of my CXF-base Web Service client. His job is to extract the content of the server response in order to save it through the persistence layer. It is attached to the RECEIVE Phase. My problem is the following : An exception is raised when I try to extract the response content, the exception is : 392906 [http-8080-Processor2] WARN org.apache.cxf.phase.PhaseInterceptorChain - Interceptor for {urn:ihe:iti:xds-b:2007}DocumentRepository_Service#{urn:ihe:iti:xds-b:2007}DocumentRepository_ProvideAndRegisterDocumentSet-b has thrown exception, unwinding now org.apache.cxf.interceptor.Fault: Couldn't find MIME boundary: --uuid:443a543d-4ab6-448c-bcb9-3bf01d2c2c3c at org.apache.cxf.interceptor.AttachmentInInterceptor.handleMessage(AttachmentInInterceptor.java:66) at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:244) at org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:729) at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:2261) at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:2134) at org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1988) at org.apache.cxf.io.CacheAndWriteOutputStream.postClose(CacheAndWriteOutputStream.java:47) at org.apache.cxf.io.CachedOutputStream.close(CachedOutputStream.java:188) at org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:66) at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:639) at org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62) at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:244) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:516) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:313) at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:265) at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73) at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:124) ... Caused by: java.io.IOException: Couldn't find MIME boundary: --uuid:443a543d-4ab6-448c-bcb9-3bf01d2c2c3c at org.apache.cxf.attachment.AttachmentDeserializer.initializeRootMessage(AttachmentDeserializer.java:122) at org.apache.cxf.attachment.AttachmentDeserializer.initializeAttachments(AttachmentDeserializer.java:91) at org.apache.cxf.interceptor.AttachmentInInterceptor.handleMessage(AttachmentInInterceptor.java:64) ... 56 more And this is clearly linked to this new interceptor as without it it works. After debugging for a while I noticed something strange : my In interceptor is actually called twice. This could maybe explain why this exception is raised. I retrieved the content of the returned message in order to check if there is a difference between the two calls. The only difference is that on the second call I have an extra propertie : exchange.finished = true. Seems that the response is sent several « packets »... Is this something normal ? Thanks in advance for your help.
