When service integration converts a message to WebSphere® MQ format, it sets fields in the MQMD and the MQRFH2 based on the service integration message header fields and properties; these include JMS message header fields and properties applicable to the message. When service integration converts a message from WebSphere MQ format, it sets the service integration message header fields and properties from the MQMD and the MQRFH2 in the WebSphere MQ message.
Usually, you do not have to be aware of conversion between message formats to exchange JMS messages between service integration and WebSphere MQ, because service integration performs the appropriate conversion automatically, including character and numeric encoding. However, you might have to learn about message conversion if your JMS applications do not behave as expected, or if your service integration configuration includes JMS programs or mediations that process messages to or from non-JMS WebSphere MQ programs.
If your service integration applications exchange MapMessage objects with WebSphere MQ applications, you might have to specify a non-default map message encoding format. For more information, see Setting the WebSphere MQ encoding format for JMS Map entries.
Similarly, service integration might receive messages from WebSphere MQ applications that generate messages with no MQRFH2. When service integration receives a message with no MQRFH2, it creates a "best guess" service integration header, by getting as much information as it can from the MQMD, and using default values for the other fields.
For detailed information about the contents of the message descriptor and the message headers, see the WebSphere MQ Application Programming Reference. For details of WebSphere MQ JMS support, including details of how WebSphere MQ stores JMS message properties and header fields in the MQMD and the MQRFH2, see WebSphere MQ Using Java.
The following table shows how service integration maps JMS header fields to and from MQMD and MQRFH2 fields when converting messages to and from WebSphere MQ format.
The table shows the MQRFH2 field as folder.field, where folder is the name of the MQRFH2 folder that contains the field, and field is the name of the field within the MQRFH2 folder.
For several JMS header fields, there is both an MQMD field and an MQRFH2 field. When service integration is converting messages to WebSphere MQ format, it sets both the MQMD and the MQRFH2 fields. When service integration is converting messages from WebSphere MQ format, it sets the JMS header field from the MQRFH2 field if it is available, otherwise from the MQMD field.
JMS header field | MQMD field | MQRFH2 field | Notes |
---|---|---|---|
JMSCorrelationID | CorrelId | jms.Cid | See Note 1. |
JMSDeliveryMode | Persistence | jms.Dlv | See Note 15. |
JMSDestination | jms.Dst | See Note 16. | |
JMSExpiration | Expiry | jms.Exp | |
JMSMessageID | MsgId | ||
JMSPriority | Priority | See Note 2. | |
JMSRedelivered | BackoutCount | See Note 3. | |
JMSReplyTo | ReplyToQ and ReplyToQMgr | jms.Rto | See Note 16. |
JMSTimestamp | PutDate and PutTime | jms.Tms | |
JMSType | mcd.Type |
The following table shows how service integration maps JMS defined properties to and from MQMD and MQRFH2 fields when converting messages to and from WebSphere MQ format.
The table shows the MQRFH2 field as folder.field, where folder is the name of the MQRFH2 folder that contains the field, and field is the name of the field within the MQRFH2 folder.
For several JMS-defined properties, there is both an MQMD field and an MQRFH2 field. When service integration is converting messages to WebSphere MQ format, it sets both the MQMD and the MQRFH2 fields. When service integration is converting messages from WebSphere MQ format, it sets the JMS defined property from the MQRFH2 field if it is available, otherwise from the MQMD field.
JMS defined property | MQMD field | MQRFH2 field | Notes |
---|---|---|---|
JMSXAppID | PutApplName | ||
JMSXDeliveryCount | BackoutCount | ||
JMSXGroupID | GroupId | jms.Gid | See Notes 4 and 5. |
JMSXGroupSeq | MsgSeqNumber | jms.Seq | |
JMSXUserID | UserIdentifier |
The following table shows how service integration maps JMS provider-specific properties to and from MQMD and MQRFH2 fields when converting messages to and from WebSphere MQ format. Typically you use these properties to satisfy special requirements in the receiving application, so you should consult the developer or administrator of the receiving application for details of the required property values.
JMS provider-specific property | MQMD field | MQRFH2 field | Notes |
---|---|---|---|
JMS_IBM_ArmCorrelator | mqext.Arm | See Note 6. | |
JMS_IBM_Character_Set | CodedCharacterSetId | CodedCharacterSetId | See Note 7. |
JMS_IBM_Encoding | Encoding | Encoding | See Note 7. |
JMS_IBM_Feedback | Feedback | ||
JMS_IBM_Format | Format | Format | See Note 7. |
JMS_IBM_Last_Msg_In_Group | MQMF_LAST_MSG_IN_GROUP | See Note 8. | |
JMS_IBM_MQMD_CorrelId | CorrelId | See Notes 9 and 10. | |
JMS_IBM_MQMD_MsgId | MsgId | See Notes 9 and 11. | |
JMS_IBM_MQMD_Persistence | Persistence | See Notes 9, 12, and 15. | |
JMS_IBM_MQMD_ReplyToQ | ReplyToQ | See Notes 9, 13, and 16. | |
JMS_IBM_MQMD_ReplyToQMgr | ReplyToQMgr | See Notes 9, 13, and 16. | |
JMS_IBM_MsgType | MsgType | ||
JMS_IBM_PutDate | PutDate | ||
JMS_IBM_PutTime | PutTime | ||
JMS_IBM_Report_* | Report | See Note 14. | |
JMS_IBM_RMCorrelator | mqext.Wrm | ||
JMS_TOG_ARM_Correlator | mqext.Arm | See Note 6. |
Service integration sets each of these properties from the corresponding MQMD field when it converts a message from WebSphere MQ format.
When service integration converts messages from WebSphere MQ format, service integration sets the JMS_IBM_MQMD_CorrelId property to the value (byte[]) of the MQMD CorrelId field, regardless of the value (if any) of the MQRFH2 jms.Cid field.
When service integration converts messages from WebSphere MQ format, service integration sets the JMS_IBM_MQMD_MsgId property to the value (byte[]) of the MQMD MsgId field.
When service integration converts messages from WebSphere MQ format, service integration sets the JMS_IBM_MQMD_Persistence property to the value (integer) of the MQMD Persistence field, regardless of the value (if any) of the MQRFH2 jms.Dlv field.
When service integration converts messages from WebSphere MQ format, service integration sets the JMS_IBM_MQMD_ReplyToQ and JMS_IBM_MQMD_ReplyToQMgr property to the values (string) of the MQMD ReplyToQ and ReplyToQMgr fields, regardless of the value (if any) of the MQRFH2 jms.Rto field.