Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

cannot enable MTOM Feature

 
Goran Markovic
Ranch Hand
Posts: 399
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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!
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
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?
Best wishes!
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi again!
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:
• webservices-api.jar
• webservices-extra-api.jar
• webservices-extra.jar
• webservices-rt.jar
• webservices-tools.jar

Best wishes!
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic