Remote queues
To a program, a queue is remote if it is owned by a different queue manager to the one to which the program is connected.
Where a communication link has been established, a program can send a message to a remote queue. A program can never get a message from a remote queue.
The queue definition object, created when you define a remote queue, only holds the information necessary for the local queue manager to locate the queue to which we want your message to go. This object is known as the local definition of a remote queue. All the attributes of the remote queue are held by the queue manager that owns it, because it is a local queue to that queue manager.
When opening a remote queue, to identify the queue we must specify either of the following:- The name of the local definition that defines the remote queue. From the viewpoint of an
application, this is the same as opening a local queue. An application does not need to know if a
queue is local or remote.
To create a local definition of a remote queue on all platforms except IBM i, use the DEFINE QREMOTE command.
On IBM i, use the CRTMQMQ command.
- The name of the remote queue manager and the name of the queue as it is known to that remote queue manager.
Local definitions of remote queues have three attributes in addition to the common attributes described in Attributes of queues. These three attributes are:
- RemoteQName
- The name that the queue's owning queue manager knows it by.
- RemoteQMgrName
- The name of the owning queue manager.
- XmitQName
- The name of the local transmission queue that is used when forwarding messages to other queue managers.
For more information about these attributes, see Attributes for queues.
If we use the MQINQ call against the local definition of a remote queue, the queue manager returns the attributes of the local definition only, that is the remote queue name, the remote queue manager name, and the transmission queue name, not the attributes of the matching local queue in the remote system.
See also Transmission queues.
Parent topic: Queues