Auto-Delete queues not getting deleted

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|

Auto-Delete queues not getting deleted

Raviv Pavel
I have an auto-delete, durable, non mirrored, not exclusive queue, that is empty (no messages), idle, and has no consumers
However, it's still not being auto deleted.
Any idea why?

_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Simon MacMullen-2
Has it *ever* had consumers? auto_delete queues will delete themselves
when their consumer count drops to 0 from a higher number. Otherwise
they would delete themselves as soon as they were declared...

Empty / idle is not relevant BTW.

Cheers, Simon

On 10/10/12 11:22, Raviv Pavel wrote:

> I have an auto-delete, durable, non mirrored, not exclusive queue, that
> is empty (no messages), idle, and has no consumers
> However, it's still not being auto deleted.
> Any idea why?
>
>
> _______________________________________________
> rabbitmq-discuss mailing list
> [hidden email]
> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>


--
Simon MacMullen
RabbitMQ, VMware
_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Raviv Pavel-2
Can't remember if they had consumers or not.
Does it also depends on the auto-delete flag of the exchange?

Thanks
--Raviv




On Wed, Oct 10, 2012 at 2:06 PM, Simon MacMullen <[hidden email]> wrote:
Has it *ever* had consumers? auto_delete queues will delete themselves when their consumer count drops to 0 from a higher number. Otherwise they would delete themselves as soon as they were declared...

Empty / idle is not relevant BTW.

Cheers, Simon

On 10/10/12 11:22, Raviv Pavel wrote:
I have an auto-delete, durable, non mirrored, not exclusive queue, that
is empty (no messages), idle, and has no consumers
However, it's still not being auto deleted.
Any idea why?


_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss



--
Simon MacMullen
RabbitMQ, VMware


_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Simon MacMullen-2
On 10/10/12 14:06, Raviv Pavel wrote:
> Can't remember if they had consumers or not.
> Does it also depends on the auto-delete flag of the exchange?

No, it's the other way round. An auto-delete exchange will delete itself
once the last queue unbinds.

Cheers, Simon


--
Simon MacMullen
RabbitMQ, VMware
_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Raviv Pavel-2
So if a queue is empty and there are no active consumers, what prevents if from being deleted?

Thanks
--Raviv




On Wed, Oct 10, 2012 at 3:50 PM, Simon MacMullen <[hidden email]> wrote:
On 10/10/12 14:06, Raviv Pavel wrote:
Can't remember if they had consumers or not.
Does it also depends on the auto-delete flag of the exchange?

No, it's the other way round. An auto-delete exchange will delete itself once the last queue unbinds.

Cheers, Simon



--
Simon MacMullen
RabbitMQ, VMware


_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Simon MacMullen-2
On 10/10/12 15:38, Raviv Pavel wrote:
> So if a queue is empty and there are no active consumers, what prevents
> if from being deleted?

As I said before, has it *ever* had consumers? If it has never had
consumers it won't be deleted.

Also, whether it is empty does not matter. It would be deleted just as
easily if it were not empty.

Cheers, Simon

--
Simon MacMullen
RabbitMQ, VMware
_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Dmitry Polyanovsky
In reply to this post by Raviv Pavel
Hi,
they will be deleted after first consumer "touch" them. If any consumer will never connect to queue, it will be never deleted.

On Wednesday, October 10, 2012 12:22:17 PM UTC+2, Raviv Pavel wrote:
I have an auto-delete, durable, non mirrored, not exclusive queue, that is empty (no messages), idle, and has no consumers
However, it's still not being auto deleted.
Any idea why?

_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Raviv Pavel-2
I find this behavior is problematic, especially when fanning out messages to temporary queues.
If I create an auto-delete queue (by code) and then crash before consuming, the queue will be stuck there until I delete it.

Is there a way to delete numerous queues by name prefix and/or state?


On Sunday, October 14, 2012 4:27:12 PM UTC+2, Dmitry Polyanovsky wrote:
Hi,
they will be deleted after first consumer "touch" them. If any consumer will never connect to queue, it will be never deleted.

On Wednesday, October 10, 2012 12:22:17 PM UTC+2, Raviv Pavel wrote:
I have an auto-delete, durable, non mirrored, not exclusive queue, that is empty (no messages), idle, and has no consumers
However, it's still not being auto deleted.
Any idea why?

_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Matthias Radestock-3
On 26/10/12 07:28, Raviv Pavel wrote:
> I find this behavior is problematic

AMQP/Rabbit could hardly do anything different - if the sole condition
for auto-deletion was that there are no consumers then the queue would
get deleted straight after creation, before you've had a chance to
attach any consumers.

> If I create an auto-delete queue (by code) and then crash before
> consuming, the queue will be stuck there until I delete it.

Couldn't you make the queue 'exclusive' instead of 'auto-delete'?

Or, alternatively, set a lease (http://www.rabbitmq.com/ttl.html#queue-ttl).

Regards,

Matthias.
_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Rosa, Andrea (HP Cloud Services)
Hi

>Couldn't you make the queue 'exclusive' instead of 'auto-delete'?

That means if I have an exclusive queue and the consumer crash the broker will take care of delete the queue?

>
>Or, alternatively, set a lease (http://www.rabbitmq.com/ttl.html#queue-
>ttl).


The lease feature is available from which version?

Thanks
--
Andrea Rosa
_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Matthias Radestock-3
Andrea,

On 26/10/12 11:12, Rosa, Andrea (HP Cloud Services) wrote:
>> Couldn't you make the queue 'exclusive' instead of 'auto-delete'?
>
> That means if I have an exclusive queue and the consumer crash the
> broker will take care of delete the queue?

Yes.

The downside of exclusive queues is that they can only have consumers on
the connection that created them. So this doesn't work for shared
queues, or queues created by some app that are subsequently to be
consumed from by some other app.

>> Or, alternatively, set a lease
>> (http://www.rabbitmq.com/ttl.html#queue-ttl).
>
> The lease feature is available from which version?

2.0.0, according to http://www.rabbitmq.com/changelog.html

Regards,

Matthias.
_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Auto-Delete queues not getting deleted

Raviv Pavel-2
In reply to this post by Matthias Radestock-3
Thanks Matthias.

Queue TTL was exactly what I needed. 

On Friday, October 26, 2012 9:47:12 AM UTC+2, Matthias Radestock wrote:
On 26/10/12 07:28, Raviv Pavel wrote:
> I find this behavior is problematic

AMQP/Rabbit could hardly do anything different - if the sole condition
for auto-deletion was that there are no consumers then the queue would
get deleted straight after creation, before you've had a chance to
attach any consumers.

> If I create an auto-delete queue (by code) and then crash before
> consuming, the queue will be stuck there until I delete it.

Couldn't you make the queue 'exclusive' instead of 'auto-delete'?

Or, alternatively, set a lease (http://www.rabbitmq.com/ttl.html#queue-ttl).

Regards,

Matthias.

_______________________________________________
rabbitmq-discuss mailing list
[hidden email]
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss