Hi,
I have a question about MTOM.

I have MTOM enabled on server and my wsdl defines the element as
<xs:element xmlns:ns1="http://www.w3.org/2005/05/xmlmime"; minOccurs="0" name
="attachment" ns1:expectedContentTypes="application/octet-stream"type="
xs:base64Binary"/>

and on the client side, my MTOM feature is *not* enabled and i am using

DataSource ds = new FileDataSource(f);

request.setAttachment(new DataHandler(ds));


and the attachment is sent inline with the soap request. Not as a
multipart. This causes my server to run outOfMemory if the file size is
big.

Is this the right behavior? if yes, this makes MTOM feature almost
un-reliable from server side as we don't have any control over the client.
Please clarify the concept for me.Is there anyway we can restrict our
client to send files as attachments?

Thanks,

Sam

Reply via email to