Move 'locking_coordinator_url' to common configuration section
The variable will now be in the 'DEFAULT' section. This is due to the fact that it is used by the NSX|V and NSX|V3 plugins. DocImpact Change-Id: I3238eafcf2fde0cb4fa6cd48099908980c28d39f
This commit is contained in:
parent
5b8e132cfb
commit
7be0400365
12
etc/nsx.ini
12
etc/nsx.ini
@ -48,6 +48,12 @@
|
||||
# This field will be used when a L2 Gateway service plugin is configured.
|
||||
# nsx_l2gw_driver =
|
||||
|
||||
# (Optional) URL for distributed locking coordination resource for lock manager
|
||||
# This value is passed as a parameter to tooz coordinator.
|
||||
# By default, value is None and oslo_concurrency is used for single-node
|
||||
# lock management.
|
||||
# locking_coordinator_url =
|
||||
|
||||
[quotas]
|
||||
# number of network gateways allowed per tenant, -1 means unlimited
|
||||
# quota_network_gateway = 5
|
||||
@ -171,12 +177,6 @@
|
||||
# (Optional) Password to configure for Edge appliance login
|
||||
# edge_appliance_password =
|
||||
|
||||
# (Optional) URL for distributed locking coordination resource for lock manager
|
||||
# This value is passed as a parameter to tooz coordinator.
|
||||
# By default, value is None and oslo_concurrency is used for single-node
|
||||
# lock management.
|
||||
# locking_coordinator_url =
|
||||
|
||||
# (Optional) DHCP lease time
|
||||
# dhcp_lease_time = 86400
|
||||
|
||||
|
@ -160,7 +160,10 @@ cluster_opts = [
|
||||
|
||||
nsx_common_opts = [
|
||||
cfg.StrOpt('nsx_l2gw_driver',
|
||||
help=_("Class path for the L2 gateway backend driver"))
|
||||
help=_("Class path for the L2 gateway backend driver")),
|
||||
cfg.StrOpt('locking_coordinator_url',
|
||||
deprecated_group='nsxv',
|
||||
help=_('A URL to a locking mechanism coordinator')),
|
||||
]
|
||||
|
||||
nsx_v3_opts = [
|
||||
@ -322,8 +325,6 @@ nsxv_opts = [
|
||||
cfg.IntOpt('dhcp_lease_time',
|
||||
default=86400,
|
||||
help=_('DHCP default lease time.')),
|
||||
cfg.StrOpt('locking_coordinator_url',
|
||||
help=_('A URL to a locking mechanism coordinator')),
|
||||
cfg.BoolOpt('metadata_initializer',
|
||||
default=True,
|
||||
help=_("If True, the server instance will attempt to "
|
||||
|
@ -26,14 +26,14 @@ LOG = log.getLogger(__name__)
|
||||
class LockManager:
|
||||
_coordinator = None
|
||||
_coordinator_pid = None
|
||||
_connect_string = cfg.CONF.nsxv.locking_coordinator_url
|
||||
_connect_string = cfg.CONF.locking_coordinator_url
|
||||
|
||||
def __init__(self):
|
||||
LOG.debug('LockManager initialized!')
|
||||
|
||||
@staticmethod
|
||||
def get_lock(name, **kwargs):
|
||||
if cfg.CONF.nsxv.locking_coordinator_url:
|
||||
if cfg.CONF.locking_coordinator_url:
|
||||
return LockManager._get_lock_distributed(name)
|
||||
else:
|
||||
# Ensure that external=True
|
||||
|
Loading…
x
Reference in New Issue
Block a user