This short tutorial discusses how the objects in a Mule event change when an external source is called through the flow. A Mule event consists of Mule message, attributes, payload and variables. The tutorial is explained with parent and child flow respectively.

Lets say that HelloFlow is the parentFlow which calls the childFlow goodbyeFlow. Will call the objects in parentFlow as A_P ( Attributes of parentFlow), P_P (payload of parentFlow) and V_P (variable of parentFlow) (see Fig 2). In case of childFlow objects are A_C ( Attributes of childFlow), P_C (payload of childFlow) and V_C (variable of childFlow) (see Fig 3) . The two queryParams passed to the parentFlow are fname and lname respectively.

Comparing Fig 2 and Fig 3 it is evident that attributes A_P gets replaced with attributes A_C. The two queryParams in parentFlow is modified with no queryParam in the childFlow. Similarly, the payload P_P is modified to P_C. However, if a response header from parentFlow then it gets added to the response header. In Fig 1 the variable in the childflow firstname refers to object which is attributes of parentFlow. Since the A_P are not transferred to child object so the var.firstName is Null.

If a variable V_P is defined in the parentFlow then it remains available even after response from the request is made. But V_C in the childFlow is not available only payload is available to the parentFlow.