Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Foreach mediator doc improvements #1272

Open
GDLMadushanka opened this issue Jan 24, 2025 · 0 comments
Open

Foreach mediator doc improvements #1272

GDLMadushanka opened this issue Jan 24, 2025 · 0 comments

Comments

@GDLMadushanka
Copy link
Contributor

Description

We need to rephrase this text to better explain what happen when we iterate on body, variable and what happen when we give a result-target

The ForEach Mediator processes a collection, such as a JSON array or XML list derived from the message body or a defined variable, by splitting it into multiple messages, each corresponding to an item in the collection. The message in each iteration is flowing through the specified mediation sequence. After flowing through the mediation sequence, the sub-messages in each iteration are merged back to the corresponding original parent collection in the original message body or variable.

We need add a note to highlight the fact that if we are iterating a variable, datatype of that variable should be XML or JSON. same for body

We are getting the following error when try to iterate on non-array.
ERROR {ForEachMediatorV2} - {api:testForeach} Expression vars.tags did not resolve to a valid array

Steps to Reproduce

N/A

Version

4.4.0

Environment Details (with versions)

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants