QuestionQ2

VerifiedDeveloping Mule Applications

Refer to the exhibits. In the color flow, both the variable called color and the payload are set to "red".

An HTTP POST request is then made to the HTTP Listener in the decideColor flow. What is the payload value at the Logger component once the HTTP Request has completed?

Question Image

Explanation

An HTTP POST uses the current Mule payload as its request body, so "red" reaches the receiving listener as the new flow's payload. Variables are per-event metadata, and the HTTP Listener creates a new event; therefore vars.color is null in the receiving flow. The conditional payload expression consequently evaluates to "white" before logging.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!