Merge "NSXv: duplicate code"

This commit is contained in:
Jenkins 2016-08-04 05:51:19 +00:00 committed by Gerrit Code Review
commit 303bcd4469
2 changed files with 1 additions and 11 deletions

View File

@ -714,16 +714,6 @@ class EdgeApplianceDriver(object):
return task_constants.TaskStatus.ERROR
return task_constants.TaskStatus.COMPLETED
def delete_portgroup(self, dvs_id, port_group_id):
task_name = "delete-port-group-%s" % port_group_id
userdata = {'dvs_id': dvs_id,
'port_group_id': port_group_id}
task = tasks.Task(task_name, port_group_id,
self._delete_port_group,
status_callback=self._delete_port_group,
userdata=userdata)
self.task_manager.add(task)
def _retry_task(self, task):
delay = 0.5
max_retries = max(cfg.CONF.nsxv.retries, 1)

View File

@ -430,7 +430,7 @@ class EdgeManager(object):
if port_group_id:
dvs_id, net_type = self._get_physical_provider_network(
context, network_id)
self.nsxv_manager.delete_portgroup(dvs_id,
self.nsxv_manager.delete_port_group(dvs_id,
port_group_id)
else:
self.nsxv_manager.vcns.update_interface(edge_id, vnic_config)