Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

No Format
$ qpid-route dynamic add localhost:10003 localhost:10004 fed.topic
$ qpid-route dynamic add localhost:10004 localhost:10003 fed.topic

Information about existing routes can be gotten by querying each broker individually:

No Format

$ qpid-route route list localhost:10003
localhost:10003 localhost:10004 fed.topic <dynamic>
$ qpid-route route list localhost:10004
localhost:10004 localhost:10003 fed.topic <dynamic>

A nicer way to view the topology is to use qpid-route route map. The argument to this command is a single broker that serves as an entry point. qpid-route will attempt to recursively find all of the brokers involved in federation relationships with the starting broker and map all of the routes it finds.

No Format

$ qpid-route route map localhost:10003

Finding Linked Brokers:
    localhost:10003... Ok
    localhost:10004... Ok

Dynamic Routes:

  Exchange fed.topic:
    localhost:10004 <=> localhost:10003

Static Routes:
  none found

More extensive and realistic examples are supplied later in this document.

Static Routing

Dynamic routing provides simple, efficient, and automatic handling of the bindings that control routing as long as the configuration keeps within a set of constraints (i.e. exchanges of the same type and name, bidirectional traffic flow, etc.). However, there are scenarios where it is useful for the administrator to have a bit more control over the details. In these cases, static routing is appropriate.

Exchange Routes

An exchange route is like a dynamic route except that the exchange binding is statically set at creation time instead of dynamically tracking changes in the network.

Static exchange routes are added and deleted using qpid-tool route add and qpid-tool route del respectively. The following example creates a static exchange route with a binding key of "global.#" on the default topic exchange:

No Format

$ qpid-route route add localhost:10001 localhost:10002 amq.topic global.#

The route can be viewed by querying the originating broker (the destination in this case, see discussion of push and pull routes for more on this):

No Format

$ qpid-route route list localhost:10001
localhost:10001 localhost:10002 amq.topic global.#

Alternatively, the route map feature can be used to

...

view the topology:

No Format

$ qpid-route route map localhost:10001

Finding Linked Brokers:
    localhost:10001... Ok
    localhost:10002... Ok

Dynamic Routes:
  none found

Static Routes:

  localhost:10001(ex=amq.topic) <= localhost:10002(ex=amq.topic) key=global.#

Queue

...

Routes

Pull vs. Push Routes

qpid-route Summary and Options

Caveats, Limitations, and Things to Avoid

Redundant Paths

Example Scenarios

Using QPID to bridge disjoint IP networks

...