Dear Sergey, Thank you for your reply. What i am really not sure is what is the best way of doing it - i really want to justify the usage of rest over soap in this case. I already went through the link you paste in your reply. What it seems to me is that in case of multiparts we can add multiple attachments to the multipart body and the examples show that even jaxb generated java types are being added as attachments, I wonder if the java types shd be added as attachments too? I thought attachments are meant to be used for something like images, and not for java types.
In my case , I have a few string parameters and a binary content to pass when calling a webservice. I would like to use multipart only to attach the binary content and then pass the string params as part of a java type and by not adding that also as an attachment. I am not really sure I understand the concept of multipart :( Thanks in advance, Priya -- View this message in context: http://cxf.547215.n5.nabble.com/Best-way-to-send-and-receive-a-document-from-a-resource-method-in-rest-based-webservice-tp5745338p5745395.html Sent from the cxf-user mailing list archive at Nabble.com.