qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Fraser Adams <fraser.ad...@blueyonder.co.uk>
Subject Re: How to create an exclusive queue?
Date Sat, 07 Dec 2013 09:09:29 GMT
On 06/12/13 18:59, Darryl L. Pierce wrote:
> On Fri, Dec 06, 2013 at 06:15:52PM +0000, Gordon Sim wrote:
>> So actually a better suggestion might be, e.g.:
>> 'my-queue; {create:always, link:{x-subscribe:{exclusive:True}}}'
> QQ - does create:always recreate the queue each time, even if it already
> exists?
No, if the queue already exists it is reused (and messages that have 
built up on it can be consumed).

One of the things I got bitten with when I first started using Qpid was 
when I created queues and bindings "on demand" via address strings. So 
If I had one binding and I changed it (say when I was tinkering around) 
what I ended up with was multiple bindings between exchange and queue :-)

I *think* that if I were to put my bindings in a "link" block, but keep 
the queue creation stuff in the node block that would have done what I'd 
expected, but TBH I've not actually tried that - I really should.

I think that in general it's good that the queue doesn't get recreated 
in the case you describe. In my scenario I'd like consumers to be able 
to create everything the first time that they connect, but if they then 
disconnect and reconnect I'd like any messages that have built up on the 
queue to remain.

Probably create:always is a bit misleading in this case, but I guess 
"create: mostly" probably sounds a bit weird :-D

I *think* that in the scenario that you illustrate above if you add 
autodelete:True then the queue will get deleted after the last 
connection closes and then recreated on the first new connection after that.


To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org

View raw message