Hi,
By reading the test case, it seems that we can pass the binary data over WS
using javax.activation.DataHandler as the java data type. MTOM can be used
to control how the binary data is serialized in the payload. Can you
confirm?
Do we support other binary data types such as java.awt.Image?
Thanks,
Raymond
From: Ramkumar R
Sent: Wednesday, November 05, 2008 11:50 PM
To: [email protected]
Subject: Update on Axis2 MTOM support in Tuscany
Support for Axis2 MTOM is now enabled with fixes available from TUSCANY-2611
following the check-in made using TUSCANY-2207 (we does not seem to
working).
As discussed in thread...
http://www.mail-archive.com/[EMAIL PROTECTED]/msg26726.html
<binding.ws requires="MTOM"/>
can be used to enable the MTOM optimization on the client/server side.
Enabling MTOM Optimization on the Client Side:
To enable MTOM optimization on the client side <binding.ws requires="MTOM"/>
should be used with the reference bindings. By enabling this feature, any
SOAP envelope, regardless of whether it contains optimizable content or not,
will be serialized as an MTOM optimized MIME message.
Enabling MTOM Optimization on the Server Side:
The Axis 2 server automatically identifies incoming MTOM optimized messages
based on the content-type and de-serializes them accordingly. The user can
enable MTOM on the server side for outgoing messages. To enable MTOM
optimization on the server side <binding.ws requires="MTOM"/> should be used
with the service bindings.
A junit test is available as part of binding-ws-axis2 module to demostrate
the same.
[http://svn.apache.org/repos/asf/tuscany/java/sca/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/]
NOTE: Any change in behaviour is not noticed through the testcase as change
is only noticed in the SOAP Envelope messages when MTOM is enabled. What you
can notice is that the MTOMStAXSOAPModelBuilder is used instead
StAXSOAPModelBuilder as the builder for SOAP messages for the
content-type:application/xop+xml.
--
Thanks & Regards,
Ramkumar Ramalingam