Quantcast
Channel: Apache Timeline
Viewing all articles
Browse latest Browse all 5648

Use of subject for routing - moved thread to user list from earlier private discussion.

$
0
0
All,
I've moved this thread to the user list. It started out on the back of
an email conversation between Rob Godfrey. Gordon Sim and and myself
when I couldn't get my QMF messages routed on the Java Broker.

The original context was that I was sending messages to
qmf.default.direct and setting the message subject to "broker", this is
pretty much exactly what the python qpid tools such as qpid-config do.

in AMQP 0.10 this works fine because the subject (which in AMQP 0.10 is
a user property called qpid.subject) gets treated as the routing key
when sent to a direct exchange.

When I did my AMQP 1.0 JavaScript qpid-config port I set the AMQP 1.0
subject (which is now an immutable message property and not an
application property) to "broker" and sent to
amqp://guest:guest [ at ] localhost:5673/qmf.default.direct

This worked fine with the C++ broker, but with the Java Broker the
message wasn't routed and in subsequent conversations with Rob and
Gordon I discovered that the Java Broker doesn't route on direct
exchanges based on Subject rather it first tries to use to "to" - in
other words if I sent to
amqp://guest:guest [ at ] localhost:5673/qmf.default.direct/broker it'd work or
if the to isn't set it uses the application property "routing-key".

So basically this thread is around an inconsistency between the C++ and
Java Brokers where the C++ Broker continues to route on Subject for AMQP
1.0 but the Java Broker does not.

Rob and Gordon can fill in if I've missed anything, but it's probably
best to share this discussion on the user list.

Frase



From my perspective I'd say exactly the opposite, that is routing by
subject seems entirely intuitive and is also consistent with what
happened with AMQP 0.10. Given the use of subject as the defacto routing
key on all of the python tools I don't think I'm alone in feeling that's
intuitive. I'm pretty sure that the subject is used for routing on topic
exchanges so I'm not sure why you think its counter-intuitive on derect
exchanges?

Viewing all articles
Browse latest Browse all 5648

Trending Articles