Merge "Remove cells topic configuration option"

This commit is contained in:
Jenkins 2017-06-07 13:22:37 +00:00 committed by Gerrit Code Review
commit 1aa527fe89
6 changed files with 13 additions and 23 deletions

View File

@ -15,3 +15,5 @@
"""
Cells
"""
TOPIC = 'cells'

View File

@ -27,6 +27,7 @@ from oslo_log import log as logging
import oslo_messaging as messaging
from oslo_serialization import jsonutils
from nova import cells
import nova.conf
from nova import exception
from nova import objects
@ -135,7 +136,7 @@ class CellsAPI(object):
def __init__(self):
super(CellsAPI, self).__init__()
target = messaging.Target(topic=CONF.cells.topic, version='1.0')
target = messaging.Target(topic=cells.TOPIC, version='1.0')
version_cap = self.VERSION_ALIASES.get(CONF.upgrade_levels.cells,
CONF.upgrade_levels.cells)
# NOTE(sbauza): Yes, this is ugly but cells_utils is calling cells.db

View File

@ -20,6 +20,7 @@ import sys
from oslo_log import log as logging
from oslo_reports import guru_meditation_report as gmr
from nova import cells
import nova.conf
from nova import config
from nova import objects
@ -39,7 +40,7 @@ def main():
gmr.TextGuruMeditation.setup_autorun(version)
server = service.Service.create(binary='nova-cells',
topic=CONF.cells.topic,
topic=cells.TOPIC,
manager='nova.cells.manager.CellsManager')
service.serve(server)
service.wait()

View File

@ -29,25 +29,6 @@ required and all Nova deployments will be at least a cells v2 cell of one.
""")
cells_opts = [
cfg.StrOpt('topic',
default='cells',
deprecated_for_removal=True,
deprecated_since='15.0.0',
deprecated_reason="""
Configurable RPC topics provide little value and can result in a wide variety
of errors. They should not be used.
""",
help="""
Topic.
This is the message queue topic that cells nodes listen on. It is
used when the cells service is started up to configure the queue,
and whenever an RPC call to the scheduler is made.
Possible values:
* cells: This is the recommended and the default value.
"""),
cfg.BoolOpt('enable',
default=False,
help="""

View File

@ -34,9 +34,9 @@ class CellsAPITestCase(test.NoDBTestCase):
def setUp(self):
super(CellsAPITestCase, self).setUp()
self.fake_topic = 'fake_topic'
self.fake_topic = 'cells'
self.fake_context = 'fake_context'
self.flags(topic=self.fake_topic, enable=True, group='cells')
self.flags(enable=True, group='cells')
self.cells_rpcapi = cells_rpcapi.CellsAPI()
def _stub_rpc_method(self, rpc_method, result):

View File

@ -0,0 +1,5 @@
---
upgrade:
- |
The cells topic configuration option has been removed. Please make sure
your cells related message queue topic is 'cells'.