Hi, I cannot enable MTOM feature, and all my binary files are transferred in the body of the SOAP. I have enabled this fature on either server and client side, as much as I could gathered on the net:
this is client side code, where I tried all of this ways of MTOM enabling :
And on the server side :
Also, I have changed XSD file for response element , in order to client receive DataHandler, not byte  :
But, my SOAP response is continuously :
So, does anyone could mark me what I am doing wrong?
Thanks in advance!
Have you tried the example in section 10.3 of my study notes?
If so, did it work as expected, that is, with MTOM enabled?
Joined: Oct 04, 2006
Also note that when you are creating the instance of MTOMFeature on the client side, I recommend supplying a boolean "true" to specify that the MTOM feature is to be enabled:
In your code, you only supply the threshold.
I have had problems using SOAPBinding in connection to enabling/disabling MTOM in the past but found the above method to be more reliable.
Also, note that you have to include the following Metro JAR files on the classpath of the CLIENT, in order for MTOM to be used: