简体   繁体   中英

How does an iterator work in wso2 esb?

Can anyone explain what is the logic behind the following statement:

iterate continueParent="true" 
preservePayload="true" attachPath="//*[local-name()='Report']" expression="$body/*
[local-name()='Report']/*[local-name()='Conversion']" sequential="true"

Let's see the Iterate mediator options.

  • inueParent="true" - Specifies that the original message should be continued.

  • preservePayload="true" - Specifies that the original message should be used as a template when creating the split messages.

  • attachPath="//*[local-name()='Report']"- To form new messages, you can specify an XPath expression for elements that the split elements are attached to (as expressed in Iterate expression). So, according to this split message will added under the Report element.

  • expression="$body/* [local-name()='Report']/*[local-name()='Conversion']" - XPath expression that matches the elements, which you want to split the message from.According to your Xpath, message will split using the //body/Report/convresion tag.

  • sequential="true" - Specifies whether split messages should be processed sequentially (True) or in parallel (False). In here True is selected, you may experience a delay due to relatively high resource consumption

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM