From c51e68136903bbfa8275185a1656f6f5a3ebd2b6 Mon Sep 17 00:00:00 2001 From: Vishvananda Ishaya Date: Fri, 28 Dec 2012 15:14:50 -0800 Subject: Don't use exclusive queues for fanout and direct The use of exclusive queues can cause issues on reconnect if the rabbit server hasn't deleted the queue already. We might as well use exclusive=False so that we can reconnect to the queue if necessary. Fixes bug 1094358 Change-Id: I35bd903737d6054e8856b0003b0b8af97fd21c91 --- openstack/common/rpc/impl_kombu.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'openstack/common/rpc/impl_kombu.py') diff --git a/openstack/common/rpc/impl_kombu.py b/openstack/common/rpc/impl_kombu.py index ced4e96..668d9b6 100644 --- a/openstack/common/rpc/impl_kombu.py +++ b/openstack/common/rpc/impl_kombu.py @@ -196,7 +196,7 @@ class DirectConsumer(ConsumerBase): # Default options options = {'durable': False, 'auto_delete': True, - 'exclusive': True} + 'exclusive': False} options.update(kwargs) exchange = kombu.entity.Exchange(name=msg_id, type='direct', @@ -269,7 +269,7 @@ class FanoutConsumer(ConsumerBase): options = {'durable': False, 'queue_arguments': _get_queue_arguments(conf), 'auto_delete': True, - 'exclusive': True} + 'exclusive': False} options.update(kwargs) exchange = kombu.entity.Exchange(name=exchange_name, type='fanout', durable=options['durable'], @@ -316,7 +316,7 @@ class DirectPublisher(Publisher): options = {'durable': False, 'auto_delete': True, - 'exclusive': True} + 'exclusive': False} options.update(kwargs) super(DirectPublisher, self).__init__(channel, msg_id, msg_id, type='direct', **options) @@ -350,7 +350,7 @@ class FanoutPublisher(Publisher): """ options = {'durable': False, 'auto_delete': True, - 'exclusive': True} + 'exclusive': False} options.update(kwargs) super(FanoutPublisher, self).__init__(channel, '%s_fanout' % topic, None, type='fanout', **options) -- cgit