Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Kombu: make reply and fanout queues expire instead of auto-delete
Right now fanout and reply queues are unconditionally created with auto-delete flag which causes a number of problems listed in bug 1495568. Replacing auto-delete with queue expiration with some sane timeout should fix all these issues at once. Another problem being fixed is that auto-delete flag does not causes the queue to be deleted if it never had consumers. An orphaned fanout queue might appear that way and it will grow indefinitely until somebody manually removes it. See bug 1515278 for details. A new rabbit_transient_queues_ttl config parameter is introduced which configures the TTL for reply and fanout queues. It is a positive integer representing timeout in seconds. By default it is set to 10 minutes. That should be enough for application to reconnect or for server to send reply to client which already died. At the same time, it seems that not so many messages could be accumulated in fanout queues during that time. DocImpact With this change RabbitMQ driver defines reply and fanout queues differently comparing with the previous release: now they are defined with queue TTL (https://www.rabbitmq.com/ttl.html#queue-ttl) instead of auto-delete flag. That helps avoid a number of issues, see commit description for details. A new rabbit_transient_queues_ttl parameter is defined which controls the TTL value. It is set to 10 minutes by default. The change does not affect upgrade in any way. Closes-bug: #1495568 Closes-bug: #1515278 Co-Authored-by: Dmitry Mescheryakov <dmescheryakov@mirantis.com> Change-Id: I83a8d09dc0cdae24c12d7043ec810529a9ce57ab
- Loading branch information
Showing
1 changed file
with
47 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters