On Wednesday, August 17, 2011 7:52:29 AM jamesnmullen wrote: > I have written a Java first web service, one of the methods needs to return > an audio file. > > The consumer on this web service only supports SwA (soap with attachments), > I am struggling to get the wsdl to include the necessary mime:part elements > so that the audio files is sent as an attachment and not in the SOAP Body > which is what happens at the moment. > > I cannot see an obvious way when writing Java first to say I want my > response to be mime multipart. Any clues on how to achieve this?
With Java first, I'm not sure there is a way with SwA. Anything modern would use MTOM for this type of case and not SwA. You can TRY annotating the param/return with @XmlAttachmentRef, but I'm not really sure what that would do. I don't think that will make it a true SwA, but it might be enough to get it into a form that is acceptable. The best bet is to get the wsdl working with the mime things and and more or less start from an interface generated from that and use that wsdl at deploy time. -- Daniel Kulp [email protected] http://dankulp.com/blog Talend - http://www.talend.com
