'Stop a loop in WSO2 ESB

I was wondering if I could stop an Iterator mediator or a foreach mediator in WSO2 ESB in-between i.e. Is there a break;(statement in Java) equivalent in WSO2 ESB.

Can I use <drop/> mediator to achieve the same ?

Thanks in advance!!



Solution 1:[1]

With version 7.2.0, you can use the <respond/> to break the foreach mediator

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Minh Tr?n