Request flow for the Message Correlator for WebSphere MQ: request-response with persistence pattern
The Request flow runs as a transactional flow.
Messages received by the request
flow are processed in the following way:
- When a message is received by the message flow, a check is made to ensure that the MQMD header contains
a reply-to queue.
An error is produced if this field is blank.
- When a message is received by the message flow, a copy of the message
MQMD header is taken and modified by setting the correlation
identifier to the message identifier. The content of the message header is saved on
a queue to preserve the original reply address. Setting the correlation
identifier in the saved header ensures that when the header is
retrieved and added to the requester response, the value is correct
and enables requester retrieval by using the correlation identifier.
- The message flow includes a subflow called RequestProcessor.
This subflow contains only a Passthrough node, therefore
no processing is performed.
You can customize this subflow in your pattern instance to add your own processing without changing the
structure of the pattern.
- The MQMD header of the incoming message is modified to replace the reply-to queue manager
and reply-to queue of the requester with the address of the input node of the Response message
flow.
- The message is forwarded to the provider application.
- The message flow might contain a subflow for logging, called Log.
You can configure the pattern to include, or exclude, the Log subflow.
- If logging is not required, the message flow ends successfully after writing the message to the
provider queue and the transaction is committed.
- The message flow also contains a subflow for error handling, called
Error.