I set option autoDelete as true for a queue, but sometime even if consumer is 0, the queue still exist How can I find the reason? and how to delete? thanks
Asked
Active
Viewed 1,094 times
1 Answers
1
From the documentation, the Auto-delete
works if:
queue that has had at least one consumer is deleted when last consumer unsubscribes
So the answer is it will get deleted as soon as a consumer subscribes then unsubscribes, so the Consumer
count gets to 0
.

Mike Doe
- 16,349
- 11
- 65
- 88
-
I already gave it, it's simple and plain. What else is there to explain? Connect to the queue then disconnect and it will get removed. – Mike Doe Sep 19 '18 at 07:30
-
1As @emix said, the queue must have had _at least one_ consumer. If you only declared the queues and then disconnected, they won't be deleted. – Luke Bakken Sep 20 '18 at 14:15