Removing deprecated variable aliases from oslo_messaging

This variable is deprecated.So we should drop it.

Change-Id: I2bd4a8e0d3d9dde1f5afb0927c5abb14f33c6d34
This commit is contained in:
Li Wei 2016-08-08 16:23:20 +08:00
parent 7f7f51ce5e
commit e2911439c1
2 changed files with 2 additions and 9 deletions

View File

@ -50,19 +50,13 @@ CONF.register_opts(notifier_opts)
LOG = logging.getLogger(__name__)
_ALIASES = {
'glance.openstack.common.rpc.impl_kombu': 'rabbit',
'glance.openstack.common.rpc.impl_qpid': 'qpid',
'glance.openstack.common.rpc.impl_zmq': 'zmq',
}
def set_defaults(control_exchange='glance'):
oslo_messaging.set_transport_defaults(control_exchange)
def get_transport():
return oslo_messaging.get_notification_transport(CONF, aliases=_ALIASES)
return oslo_messaging.get_notification_transport(CONF)
class Notifier(object):

View File

@ -121,8 +121,7 @@ class TestNotifier(utils.BaseTestCase):
mock_get_transport, mock_notifier,
url, driver):
nfier = notifier.Notifier()
mock_get_transport.assert_called_with(cfg.CONF,
aliases=notifier._ALIASES)
mock_get_transport.assert_called_with(cfg.CONF)
self.assertIsNotNone(nfier._transport)
mock_notifier.assert_called_with(nfier._transport,
publisher_id='image.localhost')