config options: Improve help for conductor
This patch improves help text for conductor related configuration options. Implements blueprint centralize-config-options-newton Change-Id: Ieb4268fa03b0037d16bcc0b83e9fb0c72849685d
This commit is contained in:
parent
e99c366543
commit
b382c09db8
@ -1,8 +1,4 @@
|
||||
# needs:fix_opt_description
|
||||
# needs:check_deprecation_status
|
||||
# needs:check_opt_group_and_type
|
||||
# needs:fix_opt_description_indentation
|
||||
# needs:fix_opt_registration_consistency
|
||||
|
||||
|
||||
# Copyright (c) 2010 OpenStack Foundation
|
||||
@ -24,55 +20,73 @@ from oslo_config import cfg
|
||||
|
||||
conductor_group = cfg.OptGroup(
|
||||
'conductor',
|
||||
title='Conductor Options')
|
||||
|
||||
use_local = cfg.BoolOpt(
|
||||
'use_local',
|
||||
default=False,
|
||||
help='DEPRECATED: Perform nova-conductor operations locally. '
|
||||
'This legacy mode was introduced to bridge a gap during '
|
||||
'the transition to the conductor service. It no longer '
|
||||
'represents a reasonable alternative for deployers. '
|
||||
'Removal may be as early as 14.0',
|
||||
deprecated_for_removal=True)
|
||||
|
||||
topic = cfg.StrOpt(
|
||||
'topic',
|
||||
default='conductor',
|
||||
help='The topic on which conductor nodes listen')
|
||||
|
||||
manager = cfg.StrOpt(
|
||||
'manager',
|
||||
default='nova.conductor.manager.ConductorManager',
|
||||
help=('DEPRECATED: Full class name for the Manager for conductor. '
|
||||
'Removal in 14.0'),
|
||||
deprecated_for_removal=True)
|
||||
|
||||
workers = cfg.IntOpt(
|
||||
'workers',
|
||||
help='Number of workers for OpenStack Conductor service. '
|
||||
'The default will be the number of CPUs available.')
|
||||
|
||||
migrate_opt = cfg.IntOpt(
|
||||
'migrate_max_retries',
|
||||
default=-1,
|
||||
help='Number of times to retry live-migration before failing. '
|
||||
'If == -1, try until out of hosts. '
|
||||
'If == 0, only try once, no retries.')
|
||||
title='Conductor Options',
|
||||
help="""
|
||||
Options under this group are used to define Conductor's communication,
|
||||
which manager should be act as a proxy between computes and database,
|
||||
and finally, how many worker processes will be used.
|
||||
""",
|
||||
)
|
||||
|
||||
ALL_OPTS = [
|
||||
use_local,
|
||||
topic,
|
||||
manager,
|
||||
workers]
|
||||
cfg.BoolOpt(
|
||||
'use_local',
|
||||
default=False,
|
||||
deprecated_for_removal=True,
|
||||
help="""
|
||||
Perform nova-conductor operations locally. This legacy mode was
|
||||
introduced to bridge a gap during the transition to the conductor service.
|
||||
It no longer represents a reasonable alternative for deployers.
|
||||
|
||||
Removal may be as early as 14.0.
|
||||
"""),
|
||||
# TODO(macsz) deprecate this option
|
||||
cfg.StrOpt(
|
||||
'topic',
|
||||
default='conductor',
|
||||
help="""
|
||||
Topic exchange name on which conductor nodes listen.
|
||||
"""),
|
||||
cfg.StrOpt(
|
||||
'manager',
|
||||
default='nova.conductor.manager.ConductorManager',
|
||||
deprecated_for_removal=True,
|
||||
help="""
|
||||
Full class name for the Manager for conductor.
|
||||
|
||||
Removal in 14.0
|
||||
"""),
|
||||
cfg.IntOpt(
|
||||
'workers',
|
||||
help="""
|
||||
Number of workers for OpenStack Conductor service. The default will be the
|
||||
number of CPUs available.
|
||||
"""),
|
||||
]
|
||||
|
||||
migrate_opts = [
|
||||
cfg.IntOpt(
|
||||
'migrate_max_retries',
|
||||
default=-1,
|
||||
min=-1,
|
||||
help="""
|
||||
Number of times to retry live-migration before failing.
|
||||
|
||||
Possible values:
|
||||
|
||||
* If == -1, try until out of hosts (default)
|
||||
* If == 0, only try once, no retries
|
||||
* Integer greater than 0
|
||||
"""),
|
||||
]
|
||||
|
||||
|
||||
def register_opts(conf):
|
||||
conf.register_group(conductor_group)
|
||||
conf.register_opts(ALL_OPTS, group=conductor_group)
|
||||
conf.register_opts([migrate_opt])
|
||||
conf.register_opts(migrate_opts)
|
||||
|
||||
|
||||
def list_opts():
|
||||
return {"DEFAULT": [migrate_opt],
|
||||
return {"DEFAULT": migrate_opts,
|
||||
conductor_group: ALL_OPTS}
|
||||
|
Loading…
Reference in New Issue
Block a user