qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sitapati das / Joshua J Wulf" <sitap...@worldsankirtan.net>
Subject Queue and exchange with the same name
Date Tue, 17 Jul 2012 00:02:46 GMT
I'm working through the Address tutorial here:

I was not expecting this behaviour:

$ spout 'amq.topic; {assert: always, node: { type: topic}}' test-message
Message(properties={'spout-id': 'ea2e7b50-4153-4d4e-8323-ca9b95e18ab4:0'},

$ qpid-config add queue amq.topic

$ spout 'amq.topic; {assert: always, node: { type: topic}}' test-message
Traceback (most recent call last):
  File "/usr/share/doc/python-qpid-0.16/examples/api/spout", line 101, in
    snd = ssn.sender(addr)
  File "<string>", line 6, in sender
  File "/usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py", line
595, in sender
    raise e
qpid.messaging.exceptions.AssertionFailed: expected topic, got queue

I expected the attempt to create a queue with the same name as an existing
exchange to fail; however, it looks like queues and exchanges can be
created with the same name.

I tested a few combinations, and when a queue and an exchange with the same
name are created, the queue always takes precedence, regardless of the
order of creation.

I was hoping that using assert would disambiguate the intended destination
of my message. Since multiple objects with the same name can be created, is
there a way to specify what class of target I mean by a name?

 - Josh

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message