Using JMS transport protocol with Message Broker

This section describes how to configure components to send and receive documents between WebSphere Partner Gateway and WebSphere Business Integration Message Broker through the use of the JMS transport protocol. It provides the following information on how to send and receive documents:

Components required for documents over JMS transport

To send or receive a document between WebSphere Partner Gateway and version 5.0 Message Broker using the JMS transport protocol, WebSphere MQ must be the JMS provider. The following sections describe how WebSphere Partner Gateway, Message Broker, and WebSphere MQ work together to exchange documents over the HTTP transport protocol.

How documents are sent over the JMS transport

For WebSphere Partner Gateway to send a document to Message Broker using the JMS transport protocol, you use the JMS queues. WebSphere Partner Gateway sends a document to its JMS output queue, where it is transferred to the JMS input queue on which Message Broker listens. When Message Broker receives a document, it retrieves it from its input queue. Message Broker's message flow contains special WebSphere MQ (JMS) transport nodes, which handle access to the JMS queues. Figure 25 provides an overview of how WebSphere Partner Gateway sends documents to Message Broker over the JMS transport protocol.

Figure 25. Message flow from WebSphere Partner Gateway to a message flow through the JMS transport protocol
This figure shows how a business object is sent from a participant to WebSphere Partner Gateway, how WebSphere Partner Gateway sends a JMS message to an output queue, and how Message Broker retrieves the message from an input queue.

The following steps describe how WebSphere Partner Gateway sends a document to a message flow within Message Broker over the JMS transport protocol:

  1. WebSphere Partner Gateway posts a message to its JMS output queue.

    If the packaging type of the document was Backend Integration, WebSphere Partner Gateway has provided custom properties in this message. The JMS message header, JMSType, is set with the content type of the payload.

    Note: Within WebSphere Partner Gateway, you must configure a gateway that identifies the JMS output queue to which WebSphere Partner Gateway sends the message and on which Message Broker is polling. For more information, see Configuration for receiving documents over the JMS transport protocol.
  2. WebSphere MQ transfers the document from the output queue on the computer where WebSphere Partner Gateway resides to the input queue that Message Broker is polling.
  3. When Message Broker sees a message on its input queue, it retrieves the message and sends it to the appropriate message flow.

    For information on how to set up this queue, see Setting up the environment for JMS transport.

  4. The MQInput node sends the document to the next node of the message flow. This node is usually a compute node.
  5. The nodes of the message flow perform the business logic.

    When business logic is complete, the message flow sends the resulting document to its MQOutput node.

  6. The MQOutput node sends the document to the appropriate queue.

How documents are received over the JMS transport

For WebSphere Partner Gateway to receive a document from Message Broker over the JMS transport protocol, you use JMS queues. Message Broker sends a document to its JMS output queue, where it is transferred to the JMS input queue on which WebSphere Partner Gateway listens. When WebSphere Partner Gateway receives a document, it retrieves it from its input queue. Message Broker's message flow contains special WebSphere MQ (JMS) transport nodes, which handle access to the JMS queues. Figure 26 provides an overview of how documents are sent from Message Broker to WebSphere Partner Gateway.

Figure 26. Message flow from a message flow to WebSphere Partner Gateway through the JMS transport protocol
This figure shows how a JMS message is sent from Message Broker to its output queue and to the input queue of WebSphere Partner Gateway.

The following steps describe how WebSphere Partner Gateway receives a document from a message flow within Message Broker over the JMS transport protocol:

  1. The message flow within Message Broker receives a document in its MQInput node.

    The message flow receives its incoming message from a JMS input queue.

  2. The MQInput queue of the message flow receives the document and sends it to the next node of the message flow. This node is usually a compute node.
  3. The nodes of the message flow perform the business logic.

    When business logic is complete, the message flow sends the resulting document to its MQOutput node.

  4. The MQOutput node sends the document to the appropriate JMS output queue.
  5. WebSphere MQ transfers the document from the queue on the computer where Message Broker resides to the queue that WebSphere Partner Gateway is polling.
  6. WebSphere Partner Gateway receives the message from its JMS input queue, as configured in its target.

    For more information on the target, see Configuring for incoming documents over JMS transport protocol. For information on how to set up this queue, see Setting up the environment for JMS transport.

Setting up the environment for JMS transport

The sending and receiving of documents to and from Message Broker involves JMS queues (remote and local). For information on how to configure WebSphere Partner Gateway for use with Message Broker over JMS, see Configuring WebSphere Partner Gateway for Message Broker. To use the JMS transport protocol with Message Broker, you can set up the JMS system that WebSphere MQ provides. Version 5.0 of Message Broker uses version 5.3 of WebSphere MQ as a JMS provider. You can use the steps in the Hub Configuration Guide to set up the JMS transport-protocol mechanism.

Important: The steps in the Hub Configuration Guide must be performed on the computer on which WebSphere Partner Gateway resides. This guide assumes that the JMS transport-mechanism required by Message Broker has already been set up as part of the Message Broker installation.

When you create your JMS queues for use between WebSphere Partner Gateway and Message Broker, consider the following points:

Table 70. Naming JMS queues for Message Broker directionality
Original queue name Directional queue name
inQ MB2HUB
outQ HUB2MB

Creating the message flow for JMS transport

For a Message Broker message flow to handle documents over the JMS transport protocol, it uses the following transport nodes:

The order of use for these transport nodes depends on the direction of communication, as follows:

Table 72. Nodes for receiving documents from Message Broker
Node type Purpose Notes and restrictions
MQInput Receives the document into the message flow This transport node receives the incoming document from a JMS input queue.
Compute Performs business-logic tasks, such as updating header information None
MQOutput Receives the document from the compute node and sends it to WebSphere Partner Gateway The value in the Queue Name field (in the Basic properties) of this transport node is the message flow output queue. WebSphere MQ must be set up so that this JMS queue sends documents to the input queue of WebSphere Partner Gateway. For more information, see Configuring for incoming documents over JMS transport protocol.

For more detailed information on how to create and configure message flow nodes, see your WebSphere Business Integration Message Broker documentation.

Copyright IBM Corp. 2003, 2005