Merge "Replace vif_portgroup_id with vif_port_id"
This commit is contained in:
commit
ce9f37d2a2
@ -1844,14 +1844,14 @@ class ConductorManager(base_manager.BaseConductorManager):
|
||||
'node': node.uuid})
|
||||
|
||||
if 'address' in portgroup_obj.obj_what_changed():
|
||||
vif = portgroup_obj.extra.get('vif_portgroup_id')
|
||||
vif = portgroup_obj.extra.get('vif_port_id')
|
||||
if vif:
|
||||
api = dhcp_factory.DHCPFactory()
|
||||
api.provider.update_port_address(
|
||||
vif,
|
||||
portgroup_obj.address,
|
||||
token=context.auth_token)
|
||||
# Log warning if there is no vif_portgroup_id and an instance
|
||||
# Log warning if there is no vif_port_id and an instance
|
||||
# is associated with the node.
|
||||
elif node.instance_uuid:
|
||||
LOG.warning(_LW(
|
||||
|
@ -3059,7 +3059,7 @@ class UpdatePortgroupTestCase(mgr_utils.ServiceSetUpMixin,
|
||||
node = obj_utils.create_test_node(self.context, driver='fake')
|
||||
pg = obj_utils.create_test_portgroup(
|
||||
self.context, node_id=node.id,
|
||||
extra={'vif_portgroup_id': 'fake-id'})
|
||||
extra={'vif_port_id': 'fake-id'})
|
||||
new_address = '11:22:33:44:55:bb'
|
||||
pg.address = new_address
|
||||
self.service.update_portgroup(self.context, pg)
|
||||
@ -3073,7 +3073,7 @@ class UpdatePortgroupTestCase(mgr_utils.ServiceSetUpMixin,
|
||||
node = obj_utils.create_test_node(self.context, driver='fake')
|
||||
pg = obj_utils.create_test_portgroup(
|
||||
self.context, node_id=node.id,
|
||||
extra={'vif_portgroup_id': 'fake-id'})
|
||||
extra={'vif_port_id': 'fake-id'})
|
||||
old_address = pg.address
|
||||
pg.address = '11:22:33:44:55:bb'
|
||||
mac_update_mock.side_effect = (
|
||||
|
Loading…
x
Reference in New Issue
Block a user