Mapping JMS messages to WebSphere MQ Everyplace messages

This section describes how the JMS message structure is mapped to a WebSphere MQ Everyplace message. It is of interest to programmers who wish to transmit messages between JMS and traditional WebSphere MQ Everyplace applications.

As described earlier, the JMS specification defines a structured message format consisting of a header, three types of property and five types of message body, while WebSphere MQ Everyplace defines a single free-format message object, MQeMsgObject. WebSphere MQ Everyplace defines some constant field names that messaging applications require, for example UniqueID, MessageID, and Priority, while applications can put data into a WebSphere MQ Everyplace message as <name, value> pairs.

To send JMS messages using WebSphere MQ Everyplace, we define a constant format for storing the information contained in a JMS message within an MQeMsgObject. This adds three top-level fields and four MQeFields objects to an MQeMsgObject, as shown in the following example.

Figure 8. Mapping a JMS message to a WebSphere MQ EveryplaceMQeMsgObject

Diagram showing how to map a JMS message to an MQeMsgObject, that is a WebSphere MQ Everyplace message. JMS message information is mapped onto the MQeMsgObject using MQeFields objects.These fields are listed in the text below.

The following sections describe the contents of these fields.



© IBM Corporation 2002. All Rights Reserved