From bfc07107e3f80a16dfe0b86f4f07e9b5a31f9109 Mon Sep 17 00:00:00 2001 From: Sumit Naiksatam Date: Thu, 25 Aug 2011 17:42:16 -0700 Subject: [PATCH] Changes qos description to string; changes extension API names for get_host and get_instance_port --- quantum/plugins/cisco/l2network_plugin.py | 10 +++++----- quantum/plugins/cisco/models/l2network_multi_blade.py | 8 ++++---- quantum/plugins/cisco/models/l2network_single_blade.py | 8 ++++---- quantum/plugins/cisco/ucs/cisco_ucs_inventory.py | 8 ++++---- 4 files changed, 17 insertions(+), 17 deletions(-) diff --git a/quantum/plugins/cisco/l2network_plugin.py b/quantum/plugins/cisco/l2network_plugin.py index 2a5ada6ff..84f5602b9 100644 --- a/quantum/plugins/cisco/l2network_plugin.py +++ b/quantum/plugins/cisco/l2network_plugin.py @@ -381,7 +381,7 @@ class L2Network(QuantumPluginBase): def create_qos(self, tenant_id, qos_name, qos_desc): """Create a QoS level""" LOG.debug("create_qos() called\n") - qos = cdb.add_qos(tenant_id, qos_name, qos_desc) + qos = cdb.add_qos(tenant_id, qos_name, str(qos_desc)) return qos def delete_qos(self, tenant_id, qos_id): @@ -451,19 +451,19 @@ class L2Network(QuantumPluginBase): credential = cdb.update_credential(tenant_id, credential_id, new_name) return credential - def get_host(self, tenant_id, instance_id, instance_desc): + def schedule_host(self, tenant_id, instance_id, instance_desc): """Provides the hostname on which a dynamic vnic is reserved""" - LOG.debug("get_host() called\n") + LOG.debug("schedule_host() called\n") host_list = self._invoke_device_plugins(self._func_name(), [tenant_id, instance_id, instance_desc]) return host_list - def get_instance_port(self, tenant_id, instance_id, instance_desc): + def associate_port(self, tenant_id, instance_id, instance_desc): """ Get the portprofile name and the device namei for the dynamic vnic """ - LOG.debug("get_instance_port() called\n") + LOG.debug("associate_port() called\n") return self._invoke_device_plugins(self._func_name(), [tenant_id, instance_id, instance_desc]) diff --git a/quantum/plugins/cisco/models/l2network_multi_blade.py b/quantum/plugins/cisco/models/l2network_multi_blade.py index 9f8958b2b..acd24d5ee 100644 --- a/quantum/plugins/cisco/models/l2network_multi_blade.py +++ b/quantum/plugins/cisco/models/l2network_multi_blade.py @@ -158,16 +158,16 @@ class L2NetworkMultiBlade(L2NetworkModelBase): self._invoke_plugin_per_device(const.UCS_PLUGIN, self._func_name(), args) - def get_host(self, args): + def schedule_host(self, args): """Provides the hostname on which a dynamic vnic is reserved""" - LOG.debug("get_host() called\n") + LOG.debug("schedule_host() called\n") return self._invoke_inventory(const.UCS_PLUGIN, self._func_name(), args) - def get_instance_port(self, args): + def associate_port(self, args): """ Get the portprofile name and the device namei for the dynamic vnic """ - LOG.debug("get_instance_port() called\n") + LOG.debug("associate_port() called\n") return self._invoke_inventory(const.UCS_PLUGIN, self._func_name(), args) diff --git a/quantum/plugins/cisco/models/l2network_single_blade.py b/quantum/plugins/cisco/models/l2network_single_blade.py index 9cb0a89e0..617d1a55d 100644 --- a/quantum/plugins/cisco/models/l2network_single_blade.py +++ b/quantum/plugins/cisco/models/l2network_single_blade.py @@ -149,16 +149,16 @@ class L2NetworkSingleBlade(L2NetworkModelBase): self._invoke_plugin_per_device(const.UCS_PLUGIN, self._func_name(), args) - def get_host(self, args): + def schedule_host(self, args): """Provides the hostname on which a dynamic vnic is reserved""" - LOG.debug("get_host() called\n") + LOG.debug("schedule_host() called\n") return self._invoke_inventory(const.UCS_PLUGIN, self._func_name(), args) - def get_instance_port(self, args): + def associate_port(self, args): """ Get the portprofile name and the device namei for the dynamic vnic """ - LOG.debug("get_instance_port() called\n") + LOG.debug("associate_port() called\n") return self._invoke_inventory(const.UCS_PLUGIN, self._func_name(), args) diff --git a/quantum/plugins/cisco/ucs/cisco_ucs_inventory.py b/quantum/plugins/cisco/ucs/cisco_ucs_inventory.py index 7b13982d6..2a90824bb 100644 --- a/quantum/plugins/cisco/ucs/cisco_ucs_inventory.py +++ b/quantum/plugins/cisco/ucs/cisco_ucs_inventory.py @@ -597,9 +597,9 @@ class UCSInventory(L2NetworkDeviceInventoryBase): LOG.debug("unplug_interface() called\n") return self._get_blade_for_port(args) - def get_host(self, args): + def schedule_host(self, args): """Provides the hostname on which a dynamic vnic is reserved""" - LOG.debug("get_host() called\n") + LOG.debug("schedule_host() called\n") instance_id = args[1] tenant_id = args[2][const.PROJECT_ID] host_name = self._get_host_name_for_rsvd_intf(tenant_id, instance_id) @@ -607,11 +607,11 @@ class UCSInventory(L2NetworkDeviceInventoryBase): LOG.debug("host_list is: %s" % host_list) return host_list - def get_instance_port(self, args): + def associate_port(self, args): """ Get the portprofile name and the device name for the dynamic vnic """ - LOG.debug("get_instance_port() called\n") + LOG.debug("associate_port() called\n") instance_id = args[1] tenant_id = args[2][const.PROJECT_ID] vif_id = args[2][const.VIF_ID] -- 2.45.2