Fix some typos

Change-Id: Id1f18847fafd769f11c23924fa50781d272d0fb1
This commit is contained in:
asarfaty 2020-01-05 14:24:03 +02:00
parent 167d1df667
commit 5779e3bfc2
6 changed files with 7 additions and 13 deletions

View File

@ -437,7 +437,7 @@ nsx_v3_opts = nsx_v3_and_p + [
"endpoint profile that will be used to perform L2 "
"bridging between networks in the NSX fabric and "
"VLANs external to NSX. If not specified, operators "
"will need to explictly create a layer-2 gateway in "
"will need to explicitly create a layer-2 gateway in "
"Neutron using the L2 gateway APIs.")),
cfg.StrOpt('default_tier0_router',
help=_("Name or UUID of the default tier0 router that will be "

View File

@ -28,7 +28,7 @@ class NsxV3AvailabilityZone(common_az.ConfiguredAvailabilityZone):
reason=_("Expected a list of names"))
def _has_native_dhcp_metadata(self):
# May be overriden by children
# May be overridden by children
return True
def get_az_opts(self):
@ -126,10 +126,8 @@ class NsxV3AvailabilityZone(common_az.ConfiguredAvailabilityZone):
self._native_md_proxy_uuid = None
def translate_configured_names_to_uuids(self, nsxlib):
# May be overriden by children
# May be overridden by children
# Default implementation assumes UUID is provided in config
# TODO(annak): refine this when we have a better picture
# what az config is relevant for policy
self._default_overlay_tz_uuid = self.default_overlay_tz
self._default_vlan_tz_uuid = self.default_vlan_tz
self._default_tier0_router = self.default_tier0_router

View File

@ -2201,7 +2201,7 @@ class NsxPluginV3Base(agentschedulers_db.AZDhcpAgentSchedulerDbMixin,
# Note that the session.rollback() function is called here.
# session.rollback() will invoke transaction.rollback() on
# the transaction this session maintains. The latter will
# deactive the transaction and clear the session's cache.
# deactivate the transaction and clear the session's cache.
#
# But depending on where the exception occurred,
# transaction.rollback() may have already been called

View File

@ -1743,7 +1743,6 @@ class NsxPolicyPlugin(nsx_plugin_common.NsxPluginV3Base):
if (actions['remove_router_link_port'] or
actions['add_router_link_port']):
# GW was changed. update GW and route advertisement
# pylint: disable=unexpected-keyword-arg
self.nsxpolicy.tier1.update_route_advertisement(
router_id,
static_routes=not new_enable_snat,
@ -1837,7 +1836,6 @@ class NsxPolicyPlugin(nsx_plugin_common.NsxPluginV3Base):
# Also create the empty locale-service as it must always exist
self.nsxpolicy.tier1.create_locale_service(router['id'])
#TODO(annak): narrow down the exception
except Exception as ex:
with excutils.save_and_reraise_exception():
LOG.error('Failed to create router %(id)s '
@ -2111,7 +2109,7 @@ class NsxPolicyPlugin(nsx_plugin_common.NsxPluginV3Base):
return info
def remove_router_interface(self, context, router_id, interface_info):
# find the subnet - it is need for removing the SNAT rule
# First get the subnet, which is needed for removing the SNAT rule
subnet = subnet_id = None
if 'port_id' in interface_info:
port_id = interface_info['port_id']

View File

@ -283,7 +283,7 @@ class RouterDistributedDriver(router_driver.RouterBaseDriver):
self._update_routes(context, router_id,
nexthop)
# In case of failure, rollbak will be done in teh plugin level
# In case of failure, rollback will be done in the plugin level
return info
def remove_router_interface(self, context, router_id, interface_info):

View File

@ -661,7 +661,6 @@ class NsxV3Plugin(nsx_plugin_common.NsxPluginV3Base,
def _init_mac_learning_profiles(self):
with locking.LockManager.get_lock('nsxv3_mac_learning_profile_init'):
if not self._get_mac_learning_profile():
# pylint: disable=unexpected-keyword-arg
self.nsxlib.switching_profile.create_mac_learning_profile(
NSX_V3_MAC_LEARNING_PROFILE_NAME,
'Neutron MAC Learning Profile',
@ -669,7 +668,6 @@ class NsxV3Plugin(nsx_plugin_common.NsxPluginV3Base,
tags=self.nsxlib.build_v3_api_version_tag())
self._get_mac_learning_profile()
if not self._get_mac_learning_disabled_profile():
# pylint: disable=unexpected-keyword-arg
self.nsxlib.switching_profile.create_mac_learning_profile(
NSX_V3_MAC_DISABLED_PROFILE_NAME,
'Neutron MAC Learning Disabled Profile',
@ -2792,7 +2790,7 @@ class NsxV3Plugin(nsx_plugin_common.NsxPluginV3Base,
network_id = None
if 'port_id' in interface_info:
port_id = interface_info['port_id']
# find subnet_id - it is need for removing the SNAT rule
# Find subnet_id which is needed for removing the SNAT rule
port = self._get_port(context, port_id)
network_id = port['network_id']
if port.get('fixed_ips'):