NSX Admin: Fix plugin identification

Change Ie2a5a4d00bd15ad838737948e2eb8eec69f3303b added entry points for
nsxv and nsxv3 plugins, this patch modifies the admin utility to
acknowledge new plugin entry points.

Change-Id: If3665d093ae50f189b8b937b6b7b9b312743070d
This commit is contained in:
Roey Chen 2017-05-23 04:49:43 -07:00
parent 8fa99768c3
commit 629b749d02
2 changed files with 4 additions and 2 deletions

View File

@ -19,6 +19,8 @@ NSX_INI = '/etc/neutron/plugins/vmware/nsx.ini'
# NSX Plugin Constants
NSXV3_PLUGIN = 'vmware_nsx.plugin.NsxV3Plugin'
NSXV_PLUGIN = 'vmware_nsx.plugin.NsxVPlugin'
VMWARE_NSXV = 'vmware_nsxv'
VMWARE_NSXV3 = 'vmware_nsxv3'
# Common Resource Constants
NETWORKS = 'networks'

View File

@ -176,9 +176,9 @@ def get_resources(plugin_dir):
def get_plugin():
plugin = cfg.CONF.core_plugin
plugin_name = ''
if plugin == constants.NSXV3_PLUGIN:
if plugin in (constants.NSXV3_PLUGIN, constants.VMWARE_NSXV3):
plugin_name = 'nsxv3'
elif plugin == constants.NSXV_PLUGIN:
elif plugin in (constants.NSXV_PLUGIN, constants.VMWARE_NSXV):
plugin_name = 'nsxv'
return plugin_name