That is obviously a bug in PayloadHelper.setXMLPayload. It's fixed in trunk now:

http://svn.apache.org/viewvc?rev=1366615&view=rev

Andreas

On Mon, Jul 2, 2012 at 1:29 PM, Wright, Peter
<[email protected]> wrote:
> Hi,
>
> I have a JMSListener that receives a JMS message containing a path to an XML 
> file on a REST server.
> A Class Mediator gets the REST-path from the message and http-GETs the XML 
> file.
> Now I want to set the XML file content as the payload of the message that is 
> then passed further
> to a SOAP service.
>
> I get the file content OK in my class mediator, but get an error when trying 
> to set
> the content as the XML payload.
>
> Java Code:
> InputStream istr = getFileFromRestServer(path);
> String xmlstr = convertStreamToString(istr);
> OMElement xmlElem = AXIOMUtil.stringToOM(xmlstr);
> PayloadHelper.setXMLPayload(mc, xmlElem);
>
> Error Message:
> java.util.ConcurrentModificationException: The current node has been removed 
> using a method other than Iterator#remove()
>
> Any ideas?
> The xmlstr and xmlElem look fine when I print them to STDOUT.
>
> I initially tried to set the payload as follows:
> mc.getEnvelope().getBody().getFirstElement().setText(xmlstr);
> instead of using setXMLPayload.
> This worked, but all the xml start tags "<" in the payload are encoded as 
> "&lt;"
>
> Thanks
> Peter
>
>
>
>
> The content of this e-mail is intended only for the confidential use of the 
> person addressed.
> If you are not the intended recipient, please notify the sender and delete 
> this email immediately.
> Thank you.

Reply via email to