Introduction to the Listener for IBM MQ

The Listener for IBM® MQ runs as a listener on an IBM MQ queue and passes messages to an RPC server. It is used to send messages received from an IBM MQ queue to an RPC server application. This means that existing RPC servers can be used for communication with IBM MQ. This document covers the following topics:


Overview

The Listener for IBM® MQ receives asynchronous and synchronous messages from an IBM MQ queue and calls a standard RPC server. The Listener for IBM MQ uses the IBM® MQ base Java classes from IBM. It can connect to an IBM MQ either as an IBM MQ client using TCP/IP (client mode) or in so-called bindings mode where it is connected directly to IBM® MQ running on the same machine. Note that on z/OS, only bindings mode is supported. If the Listener for IBM MQ wants to connect in client mode via TCP/IP to an MQ server on z/OS, the client attachment feature needs to be installed on the target queue manager.

The Listener for IBM MQ runs as a listener on an MQ queue and processes MQ messages. It receives an MQ message and sends the message to an RPC server. A synchronous scenario is possible if the MQ message is a request message that specifies a reply queue. In this case the result returned by the RPC server is sent back as an MQ message to the reply queue.

The Listener for IBM MQ can process MQ messages in the following formats:

  • XML/SOAP
    MQ messages in XML or SOAP format can be mapped to a Software AG IDL file, using XML Mapping Editor. The resulting XMM file has to be specified by the configuration property entirex.bridge.xmm. EntireX configuration parameters inside the XML/SOAP payload are ignored. See XML/SOAP Listener under Writing Advanced Applications with the XML/SOAP Wrapper.

  • Text
    MQ messages in text format use an IDL file, which describes the message layout (see Mapping IDL Data Types to the MQ Message Buffer). The IDL file has to be specified by the configuration property entirex.bridge.idl. The program name is taken from the applicationIdData field of the incoming MQ message. If this field is empty and the IDL file has only one program this program will be called. A custom logic (e.g. using the first n bytes of the MQ message payload) can be implemented in the user exit.

Receiving a Message from an IBM MQ Queue

graphics/receiveMessage.png

Note:
All messages retrieved by the Listener for IBM MQ from the MQ input queue are passed to the same RPC service. Messages are retrieved in the order they appear on the queue.

Sending a Message to an IBM MQ Queue

graphics/sendMessage.png

Note:
All messages sent to a Listener for IBM MQ instance via a specific RPC service are put on the same MQ output queue.