Mapping property descriptor fields into MQRFH2 headers

When a property is translated into an MQRFH2 element the following element attributes are used to specify the significant fields of the property descriptor: This describes how MQPD fields are translated to MQRFH2 element attributes.


Support

The Support property descriptor field is split into three element attributes

  • The sr element attribute specifies values in the MQPD_REJECT_UNSUP_MASK bit mask.
  • The sa element attribute specifies values in the MQPD_ACCEPT_UNSUP_MASK bit mask.
  • The sx element attribute specifies values in the MQPD_ACCEPT_UNSUP_IF_XMIT_MASK bit mask.

These element attributes are only valid in the <mq> folder and are ignored if set on elements in the other folders containing properties.

Support value MQRFH2 element attribute MQRFH2 attribute value
MQPD_SUPPORT_OPTIONAL sa optional

This is the default value.

MQPD_SUPPORT_REQUIRED sr required
MQPD_SUPPORT_REQUIRED_IF_LOCAL sx local


Context

Use the context element attribute to indicate the message context to which a property belongs. Use one value only. This element attribute is valid on a property in any folder containing properties.

Context value MQRFH2 attribute value
MQPD_NO_CONTEXT none

This is the default value.

MQPD_USER _CONTEXT user


CopyOptions

Use the copy element attribute to indicate messages into which a property should be copied. More than one value is acceptable; separate multiple values with a comma. For example copy='reply' and copy='publish,report' are both valid. This element attribute is valid on a property in any folder containing properties. Note: In the attribute definition, single quotation marks or double quotation marks are valid use, for example copy='reply' or copy="report"

CopyOption value MQRFH2 attribute value
MQPD_COPY_FORWARD forward
MQPD_COPY_REPLY reply
MQPD_COPY_REPORT report
MQPD_COPY_PUBLISH publish
MQPD_COPY_ALL all

Do not specify this with any other value. When used with another value, this takes precedence over any value except none.

MQPD_COPY_DEFAULT default

This is the default value. It is equivalent to specifying the three values MQCOPY_FORWARD, MQCOPY_REPORT and MQCOPY_PUBLISH.

Do not specify this with any other value.

MQPD_COPY_NONE none

Do not specify this with any other value. When used with another value, this takes precedence.


Restrictions to the <mq> MQRFH2 folder

When a message is put on to a queue, it is searched for an <mq> folder so that the message can be processed according to its MQ-defined properties. To allow the efficient parsing of MQ-defined properties, the following restrictions apply to the folder:

  • Only properties in the first significant <mq> folder in the message are acted upon by MQ; properties in any other <mq> folder in the message are ignored.
  • If the folder is in UTF-8, only single-byte UTF-8 characters are allowed in the folder. A multi-byte character in the folder, can cause parsing to fail, and the message to be rejected.
  • Do not include MQRFH2 groups in the <mq> folder. The presence of Unicode character U+003C in a property value will cause the message to be rejected.
  • Do not use escape strings in the folder. An escape string is treated as the actual value of the element.
  • Only Unicode character U+0020 is treated as white space within the folder. All other characters are treated as significant and can cause parsing of the folder to fail, and the message to be rejected.

If parsing of the <mq> folder fails, or if the folder does not observe these restrictions, the message is rejected with CompCode MQCC_FAILED and Reason MQRC_RFH_RESTRICTED_FORMAT_ERR. Parent topic: Properties specified as MQRFH2 elements