Using a WMQ queue manager alias to implement a remapping from one queue manager to another

Technote (FAQ)


Question

A WebSphere MQ (WMQ) queue manger alias can be used to reroute messages and thus, it should be feasible to use it to remap the destination queue manager. Is there a way to set up a system using a queue manager alias to do the remapping from one queue manager to another?

Answer

To implement this system, you create three queue managers: QM1, QM2, and QM3. The objects of the three queue managers are defined as bellow.

Queue Manager QM1:

DEF QL(TQ) USAGE(XMITQ)

DEF QR(RQ) RQMNAME(QM_ALIAS) RNAME(LQ) XMITQ(TQ)

DEF CHANNEL(QM1.QM) CHLTPYE(SDR) CONNAME(‘host2(port2),host3(port3)’) XMITQ(TQ) NPMSPEED(FAST)

Queue Manager QM2:

DEF QL(LQ)

DEF QR(QM_ALIAS) RQMNAME(QM2)

DEF CHANNEL(QM1.QM) CHLTYPE(RCVR) NPMSPEED(FAST)

DEF LISTENER(LISTENER2) TRPTYPE(TCP) PORT(port2)

Queue Manager QM3:

DEF QL(LQ)

DEF QR(QM_ALIAS) RQMNAME(QM3)

DEF CHANNEL(QM1.QM) CHLTYPE(RCVR) NPMSPEED(FAST)

DEF LISTENER(LISTENER3) TRPTYPE(TCP) PORT(port3)

At the beginning, QM1 connects to QM2. When QM2 is down, QM1 can switch to QM3.

From the definitions, you can see

  • The sender channel QM1.QM on QM1 has two connection strings, which are the addresses for QM2 and QM3.
  • QM1 does not know the name of QM2 and QM3. It just knows the alias QM_ALIAS.
  • QM2 and QM3 have definitions with the same object name, such as the local queue LQ, the queue manager alias QM_ALIAS, and the receiver channel QM1.QM. So, QM3 can be the backup when QM2 is down.
  • PLEASE NOTE: This method only works for non-persistent messages and the channel attribute NPMSPEED must be set to FAST. You can not set NPMSPEED to NORMAL because it uses transactions, and transactions are not supported when reconnecting to another host.

Reference:

WebSphere MQ > Product overview > Technical overview > Concepts of intercommunication
Queue manager alias definitions
Queue manager alias definitions apply when an application that opens a queue to put a message, specifies the queue name and the queue manager name.

Queue manager alias definitions have three uses:
- When sending messages, remapping the queue manager name
- When sending messages, altering or specifying the transmission queue
- When receiving messages, determining whether the local queue manager is the intended destination for those messages

Related information

How to implement a remapping using WMQ queue manager

Product Alias/Synonym

WebSphere MQ WMQ

Rate this page:

(0 users)Average rating

Add comments

Document information


More support for:

WebSphere MQ
Recovery

Software version:

7.0, 7.0.1, 7.1, 7.5

Operating system(s):

AIX, HP-UX, Linux, Solaris, Windows

Software edition:

All Editions

Reference #:

1622933

Modified date:

2013-10-28

Translate my page

Machine Translation

Content navigation