This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Web Services Certification (SCDJWS/OCEJWSD) and the fly likes MTOM example Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » Web Services Certification (SCDJWS/OCEJWSD)
Bookmark "MTOM example" Watch "MTOM example" New topic
Author

MTOM example

Poornima Sharma
Ranch Hand

Joined: Sep 09, 2008
Posts: 114
I am trying to run an example of sending the byte[] as attachment in webservice. To implement this, I used @MTOM(enabled=true). But when i use soapUI or java client to verify the attachments, i see the data coming as part of the xml rather than being a part of the attachment.

I also went through the MTOM example link and made changes in soap ui accordingly. But the response remained same. (I am using glassfish 3.1.2)

To create the java client I used



and verified the response using handler, but the received byte array was a part of the envelope rather than being a part of attachment.

If anyone has a running example then please forward me the same.

Thanks,


Poornima Sharma
SCJP 6.0
Poornima Sharma
Ranch Hand

Joined: Sep 09, 2008
Posts: 114
Hi Friends,

I am able to run it successfully in tomcat using Axis 2. But it is not working with glassfish.

Thanks,
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: MTOM example
 
Similar Threads
cannot enable MTOM Feature
sending pdf or any attachment from a java webservice to java client using JAX-WS and SAAJ
When use mtom to transfer one file, server log shows the file is accessed twice.
Content is not allowed in prolog
WebServiceProvider annotation