IBM BPM, V8.0.1, All platforms > Get started with IBM BPM > Key concepts > Bindings > Binding types > WebSphere MQ bindings

WebSphere MQ headers

WebSphere MQ headers incorporate certain conventions for conversion to the service component architecture (SCA) messages.

WebSphere MQ messages consist of a system header (the MQMD), zero or more other MQ headers (system or custom), and a message body. If multiple message headers exist in the message, the order of the headers is significant.

Each header contains information describing the structure of the following header. The MQMD describes the first header.


How MQ headers are parsed

An MQ Header data binding is used to parse MQ headers. The following headers are supported automatically:

Headers that start with MQH are handled differently. Specific fields of the header are not parsed; they remain as unparsed bytes.

For other MQ headers, you can write custom MQ header data bindings to parse those headers.


How MQ headers are accessed

MQ headers can be accessed in the product in one of two ways:

MQ headers are represented internally with the SMO MQHeader element. MQHeader is a container of header data that extends MQControl but contains a value element of anyType. It contains the MQMD, MQControl (MQ message body control information), and a list of other MQ headers.

The MQ header chain is unwound so that, inside the SMO, each MQ header carries its own control information (CCSID, Encoding, and Format). Headers can be added or deleted easily, without altering other header data.


Setting fields in the MQMD

You can update the MQMD using the Context API or through the service message object (SMO) in a mediation. The following fields are automatically propagated to the outbound MQ message:

Configure the MQ binding on an Import or Export to propagate the following properties to the outbound MQ message:

MsgID

Set Request Message ID to copy from SCA message.

MsgType

Clear the Set message type to MQMT_DATAGRAM or MQMT_REQUEST for request-response operation check box.

ReplyToQ

Clear the Override reply to queue of request message check box.

ReplyToQMgr

Clear the Override reply to queue of request message check box.

From version 7.0 onwards, context fields can be overridden using a custom property on the JNDI destination definition. Set the custom property MDCTX with value SET_IDENTITY_CONTEXT on the send destination to propagate the following fields to the outbound MQ message:

Set the custom property MDCTX with value SET_ALL_CONTEXT on the send destination to propagate the following properties to the outbound MQ message:

Some fields are not propagated to the outbound MQ message. The following fields are overridden during the send of the message:

WebSphere MQ bindings


Related concepts:
JMS headers