MQRFH2 headers that are not valid

At the time an MQPUT, MQPUT1, or MQGET call processes, a partial parsing of any MQRFH2 headers in the message can occur to check what folders are included, and to determine if the folders contain properties. Overview of MQRFH2 headers that are not valid.

If the partial parsing of the message cannot complete successfully because the structure is not valid, for example, the StrucLength field is too small, then:
  • The MQPUT or MQPUT1 call fails with reason code MQRC_RFH_ERROR, if it can be determined that the application includes some WebSphere® MQ Version 7 option, so that existing applications do not fail.
  • The MQGET call returns successfully, and the MQRFH2 containing the error is returned in the buffer you provided.
If the partial parsing fails because it cannot be detected whether a particular folder contains properties or not, for example, the folder begins <<jms, so parsing fails before the folder name is determined, then:
  • The MQPUT or MQPUT1 call fails with reason code MQRC_RFH_FORMAT_ERROR, if it can be determined that the application includes some WebSphere MQ Version 7 option, so that existing applications do not fail.
  • The MQGET call returns successfully, and the MQRFH2 containing the error is returned in the buffer you provided.
  • While internally within the queue manager, the message is not rejected due to the badly formatted folder, but the folder is always treated as if no properties were contained inside it.
A message can flow through the queue manager network with a folder containing such a syntax error, but never being parsed and detected, while one or more folders in the message are:
  • Valid
  • Successfully parsed
  • Used in the processing of the message
Therefore, detection is not guaranteed.

If one of your applications uses MQSETMP - Set message property, or MQINQMP to access a property, and in so doing this causes an MQRFH2 folder to be fully parsed, detecting an error such that parsing cannot complete, this is indicated by an appropriate return code to the API call. No properties in the folder are made available to the application.

If an attempt is made to fully parse an MQRFH2 folder and the parser finds unrecognized element attributes, or an unrecognized data type, parsing continues and complete successfully with no warnings being issued; this does not constitute a parsing error.