Routed Queues


With respect to routing, queues differ from topics in several respects:

The left side of Figure 27 depicts an enterprise with three servers—P, R and S—connected by routes. The remainder of Figure 25 illustrates the mechanisms that routes queue messages among servers (center) and their clients (right side).

Figure 27 Routing: Queues

Owner & Home

Server R defines a global queue named Q1. R is the owner of Q1.

Servers P and S define routed queues Q1@R. This designation indicates that these queues depend upon and reflect their home queue (that is, Q1 on server R). Notice that the designation Q1@R is only for the purpose of configuration; clients of P refer to the routed queue as Q1.

Example

When J sends a message to Q1, server P forwards the message to the home queue—Q1 on server R.

Now the message is available to receivers on all three servers, P, R and S—although only one client can consume the message. Either Q1 on P receives it on behalf of K; or Q1 on S receives it on behalf of N; or M receives it directly from the home queue.

Producers

From the perspective of producer clients, a routed queue stores messages and forwards them to the home queue. For example, when J sends a message to Q1 on server P, P forwards it to the queue owner, R, which delivers it to Q1 (the home queue).

The message is not available for consumers until it reaches the home queue. That is, client K cannot consume the message directly from server P.

If server R fails, or the route connection from P to R fails, P continues to store messages from K in its queue. When P and R resume communication, P delivers the stored messages to Q1 on R.

Consumers

From the perspective of consumer clients, a routed queue acts as a proxy receiver. For example, when L sends a message to Q1 on server R, Q1 on P can receive it from R on behalf of K, and immediately gives it to K.

If server P fails, or the route connection from P to R fails, K cannot receive messages from Q1 until the servers resume communication. Meanwhile, M and N continue to receive messages from Q1. When P and R resume communication, K can again receive messages through Q1 on P.

Configuration

You must explicitly configure each routed queue in queues.conf—clients cannot create routed queues dynamically.

You may use the administration tool or API to configure routed queues; see addprop queue and create queue .

To configure a routed queue, specify the queue name and the server name of the queue owner; for example, on server P, configure:

 Q1@R global
It is legal to use this notation even for the home queue. The queue owner recognizes its own name, and ignores the location designation (@R).
 

It is illegal to configure a routed queue as exclusive.

Browsing

Queue browsers cannot examine routed queues. That is, you can create a browser only on the server that owns the home queue.

Transactions

XA sessions do not support routed queues.


TIBCO Enterprise Message Service™ User’s Guide
Software Release 4.3, February 2006
Copyright © TIBCO Software Inc. All rights reserved
www.tibco.com