[jboss-user] [JBoss Web Services] - MTOM XOP attachments missing

Libor Krzyžanek do-not-reply at jboss.com
Mon May 27 06:34:53 EDT 2013

Libor Krzyžanek [https://community.jboss.org/people/lkrzyzanek] replied to the discussion

"MTOM XOP attachments missing"

To view the discussion, visit: https://community.jboss.org/message/819587#819587

Hello Together,
I hope enybody have had already the issue and solved it. 
The issue:
I have implemented some webservice client in standard way having wsdl, having port (with mtom annotation) and service. In XSD needed parts set to type base64 and xsi:mimeType also set:

<xs:element name="Document" type="xs:base64Binary" xmime:expectedContentTypes="*/*" />

In JAXB classes DataHandler used and XmlMimeType respectivelly. 

@XmlElement(name = "Document")
protected DataHandler document;

In proxy class I am setting MTOM enabled for binding.

First of all I was running the client in JDK (where standard JAX-WS implementation is from Sun). Runs perfectly. Then I used the library in JBoss 7.2 (cxf) and I missed attached documents. So I used the same apache-cxf library on JDK and have the same problem - means that handling in CXF ist different than in metro.

In proxy class I set also timeouts to request context - nothing happend. I am using SOAPHandlers - can it be a problem? Because I know now, that cxf based on streaming so if I am reading content of messages it probably can cause problems.

But still it is not clear why the same peace of code based on standards works with standard jdk and doesnot work with CXF. 

Does anybody had same issues with MTOM and XOP?
Thank you in advance!

Reply to this message by going to Community

Start a new discussion in JBoss Web Services at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20130527/6adc1a3f/attachment-0001.html 

More information about the jboss-user mailing list