How the MQGet node processes messages
The MQGet node processes each message that it receives.
This topic contains the following sections:
Propagating the message
- If an MQ Message Descriptor header (MQMD) is present in the input tree, the MQGet node uses it. If not, the node creates a default MQMD.
- The node also creates a default MQ Get Message Options (MQGMO)
structure based on the values that you have set for the node properties.
If an MQGMO is present in the input tree, the node uses its content
to modify the default one.When you include an MQGMO to override the default one, you must specify all the options that you are replacing. For example, if you set the option field to MQGMO_CONVERT, that value overrides all options that you set with the IBM® App Connect Enterprise Toolkit. If you do not use an overriding MQGMO, IBM App Connect Enterprise uses the following values:
- If Wait interval is not zero, MQGMO_WAIT is set; otherwise, MQGMO_NOWAIT is used.
- If Transaction mode is set to Yes, MQGMO_SYNCPOINT is used.
- If Transaction mode is set to No, MQGMO_NOSYNCPOINT is used.
- If Transaction mode is set to Automatic, MQGMO_SYNCPOINT_IF_PERSISTENT is used.
- The only other option that is used by default in the node properties is MQGMO_COMPLETE_MSG, which is set if Transaction mode is set to Yes or No. This option is not set when your integration node is running on z/OS®.
- No other options are used by default.
- The node makes the MQGet call to IBM MQ.
- The node analyzes the completion code (CC), and propagates the message to the appropriate terminal:
The following diagram shows this processing:
Constructing OutputLocalEnvironment
- If the Generate Mode property
on the MQGet node is set
to an option that does not include LocalEnvironment,
the node copies the input local environment tree to the output local
environment tree.
If this copy is made, any updates that are made in this node to the output local environment tree are not propagated downstream.
- If the Copy Local Environment property is set to an option other than None, the node copies the input local environment tree to the output local environment tree.
- If the output data location points to the output local environment tree, the node applies changes in that tree by copying from the result tree.
- The local environment tree is propagated.
The following diagram shows this processing:
Constructing the Output message
- If the Generate Mode property on the MQGet node is set to an option that does not include Message, the node copies the input message tree to the output message tree. Go to step 5.
- If the Output Data Location property is set to OutputRoot, the node creates the output message tree entirely from the result tree. Go to step 5.
- If the Copy Message property is set to a value other than None, the node copies the input message tree to the output message tree.
- If the Output Data Location property points to a part of the output message tree, the node applies changes in that tree by copying from the result tree at the point that is defined by the Result Data Location property.
- The message tree is propagated.
The following diagram shows this processing:
For an example of how this processing is implemented in a message flow, see How the MQGet node implements IBM MQ MQGet API calls.