[ http://issues.apache.org/jira/browse/AXIS2-752?page=all ]
Thilina Gunarathne resolved AXIS2-752:
--------------------------------------
Resolution: Fixed
OMText.isComplete() method was overriding the isComplete() from OMNodeImpl. I
found out that OMText.isComplete() returns "true" always. Returning true is
correct for all the cases except when creating an OMText from an XOP:Include.
In XOP:include case we have to deal with the endElement event from the parser.
If we set the complete() true in that case the end element event will be
considered as the end element of the parent element.
This is the reason for the behaviour noted in the jira.
OMText.isComplete() is removed in
http://svn.apache.org/viewvc?view=rev&revision=408182
This issue was fixed in .9 as well..
Need to put in a test case to make sure it won't be broken again..
> Problem handling multiple binary MTOM attachments
> -------------------------------------------------
>
> Key: AXIS2-752
> URL: http://issues.apache.org/jira/browse/AXIS2-752
> Project: Apache Axis 2.0 (Axis2)
> Type: Bug
> Versions: 1.0
> Environment: Windows XP, Tomcat 5.5, Eclipse + Sysdeo Tomcat Plugin
> Reporter: Timo Ahokas
> Priority: Critical
> Attachments: TestCode.zip
>
> When sending client message with multiple MTOM/binary attachments, the server
> side builds the OMElement up incorrectly. The first attachment seems to to
> it's correct location, but any additional attachments either are attached to
> the parent element or disappear (if not deep enough).
> Reproducable test case attached, which does the following:
> 1) Client constructs a message to the server with an XML document and 3
> binary attachments.
> 2) Server echoes the element back to the client.
> As seen from the SOAP message examples below, the echoed message as has the
> binary attachments attached to incorrect elements.
> Client sends:
> <?xml version="1.0" encoding="UTF-8"?>
> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
> <soapenv:Header/>
> <soapenv:Body>
> <MTOMAttachmentWS:service
> xmlns:MTOMAttachmentWS="http://MTOMAttachmentWS.test">
> <MTOMAttachmentWS:payload>
> <TestContent>test</TestContent>
> </MTOMAttachmentWS:payload>
> <MTOMAttachmentWS:attachments>
> <MTOMAttachmentWS:attachmentsDeep>
> <MTOMAttachmentWS:attachment1
> MTOMAttachmentWS:fileName="test1.jpg">
> <xop:Include
> href="cid:1.urn:uuid:[EMAIL PROTECTED]"
> xmlns:xop="http://www.w3.org/2004/08/xop/include"/>
> </MTOMAttachmentWS:attachment1>
> <MTOMAttachmentWS:attachment2
> MTOMAttachmentWS:fileName="test2.jpg">
> <xop:Include
> href="cid:2.urn:uuid:[EMAIL PROTECTED]"
> xmlns:xop="http://www.w3.org/2004/08/xop/include"/>
> </MTOMAttachmentWS:attachment2>
> <MTOMAttachmentWS:attachment3
> MTOMAttachmentWS:fileName="test3.jpg">
> <xop:Include
> href="cid:3.urn:uuid:[EMAIL PROTECTED]"
> xmlns:xop="http://www.w3.org/2004/08/xop/include"/>
> </MTOMAttachmentWS:attachment3>
> </MTOMAttachmentWS:attachmentsDeep>
> </MTOMAttachmentWS:attachments>
> </MTOMAttachmentWS:service>
> </soapenv:Body>
> </soapenv:Envelope>
> Server echoes back:
> <?xml version="1.0" encoding="UTF-8"?>
> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
> <soapenv:Header/>
> <soapenv:Body>
> <MTOMAttachmentWS:service
> xmlns:MTOMAttachmentWS="http://MTOMAttachmentWS.test"
> xmlns:tns="http://MTOMAttachmentWS.test">
> <MTOMAttachmentWS:payload>
> <TestContent>test</TestContent>
> </MTOMAttachmentWS:payload>
> <MTOMAttachmentWS:attachments>
> <MTOMAttachmentWS:attachmentsDeep>
> <MTOMAttachmentWS:attachment1
> MTOMAttachmentWS:fileName="test1.jpg">
> <xop:Include
> href="cid:1.urn:uuid:[EMAIL PROTECTED]"
> xmlns:xop="http://www.w3.org/2004/08/xop/include"/>
> </MTOMAttachmentWS:attachment1>
> </MTOMAttachmentWS:attachmentsDeep>
> <MTOMAttachmentWS:attachment2
> MTOMAttachmentWS:fileName="test2.jpg">
> <xop:Include
> href="cid:2.urn:uuid:[EMAIL PROTECTED]"
> xmlns:xop="http://www.w3.org/2004/08/xop/include"/>
> </MTOMAttachmentWS:attachment2>
> </MTOMAttachmentWS:attachments>
> <MTOMAttachmentWS:attachment3
> MTOMAttachmentWS:fileName="test3.jpg">
> <xop:Include href="cid:3.urn:uuid:[EMAIL
> PROTECTED]" xmlns:xop="http://www.w3.org/2004/08/xop/include"/>
> </MTOMAttachmentWS:attachment3>
> </MTOMAttachmentWS:service>
> </soapenv:Body>
> </soapenv:Envelope>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]