diff options
| author | Mark McLoughlin <markmc@redhat.com> | 2013-01-08 06:48:04 +0000 |
|---|---|---|
| committer | Mark McLoughlin <markmc@redhat.com> | 2013-01-08 10:23:40 +0000 |
| commit | 580df542609eae01358d14f84bbeb278e8f86eac (patch) | |
| tree | 8a4f33d2045df9a62031f756911eeab9a6d8e779 /nova | |
| parent | 9714f31f37e48e9c6f0fca3b3b6e8cd047769b09 (diff) | |
| download | nova-580df542609eae01358d14f84bbeb278e8f86eac.tar.gz nova-580df542609eae01358d14f84bbeb278e8f86eac.tar.xz nova-580df542609eae01358d14f84bbeb278e8f86eac.zip | |
Move network_topic into nova.network.rpcapi
The network_topic opt is only used in nova.network.rpcapi and it makes
sense for the RPC module to "own" the topic option.
blueprint: scope-config-opts
Change-Id: Icd779f34df47ac6dd048b3e41995e872d8859872
Diffstat (limited to 'nova')
| -rw-r--r-- | nova/config.py | 3 | ||||
| -rw-r--r-- | nova/network/rpcapi.py | 8 | ||||
| -rw-r--r-- | nova/tests/network/test_rpcapi.py | 1 |
3 files changed, 7 insertions, 5 deletions
diff --git a/nova/config.py b/nova/config.py index d6f63d602..fd3d0cc66 100644 --- a/nova/config.py +++ b/nova/config.py @@ -56,9 +56,6 @@ global_opts = [ cfg.StrOpt('scheduler_topic', default='scheduler', help='the topic scheduler nodes listen on'), - cfg.StrOpt('network_topic', - default='network', - help='the topic network nodes listen on'), cfg.ListOpt('enabled_apis', default=['ec2', 'osapi_compute', 'metadata'], help='a list of APIs to enable by default'), diff --git a/nova/network/rpcapi.py b/nova/network/rpcapi.py index 4f8ebeb22..2f52add57 100644 --- a/nova/network/rpcapi.py +++ b/nova/network/rpcapi.py @@ -23,8 +23,14 @@ from nova.openstack.common import jsonutils from nova.openstack.common import rpc from nova.openstack.common.rpc import proxy as rpc_proxy +rpcapi_opts = [ + cfg.StrOpt('network_topic', + default='network', + help='the topic network nodes listen on'), +] + CONF = cfg.CONF -CONF.import_opt('network_topic', 'nova.config') +CONF.register_opts(rpcapi_opts) class NetworkAPI(rpc_proxy.RpcProxy): diff --git a/nova/tests/network/test_rpcapi.py b/nova/tests/network/test_rpcapi.py index 032996209..90bffeeaf 100644 --- a/nova/tests/network/test_rpcapi.py +++ b/nova/tests/network/test_rpcapi.py @@ -25,7 +25,6 @@ from nova.openstack.common import rpc from nova import test CONF = cfg.CONF -CONF.import_opt('network_topic', 'nova.config') class NetworkRpcAPITestCase(test.TestCase): |
