Add dhcp to Fdb extension's permitted device owners

Change-Id: I8c15f340b82424de44f5477ce36b67efe76dee59
Closes-Bug: #1599473
Edan David 7 years ago
parent 95472a8969
commit b6592c7372

@ -54,11 +54,18 @@ class FdbPopulationAgentExtension(agent_extension.AgentCoreResourceExtension):
# - device owner "compute": updates the FDB with normal port instances,
# required in order to enable communication between
# SR-IOV direct port instances and normal port instance.
# - device owner "router_interface": updates the FDB woth OVS/LB ports,
# - device owner "router_interface": updates the FDB with OVS/LB ports,
# required in order to enable communication for SR-IOV instances
# with floating ip that are located with the network node.
# - device owner "DHCP": not required because messages are broadcast.
PERMITTED_DEVICE_OWNERS = {'compute', 'network:router_interface'}
# - device owner "DHCP": updates the FDB with the dhcp server.
# When the lease expires a unicast renew message is sent
# to the dhcp server. In case the FDB is not updated
# the message will be sent to the wire, causing the message
# to get lost in case the sender uses direct port and is
# located on the same hypervisor as the network node.
class FdbTableTracker(object):
"""FDB table tracker is a helper class

@ -128,7 +128,7 @@ class FdbPopulationExtensionTestCase(base.BaseTestCase):
fdb_extension = self._get_fdb_extension(mock_execute, '')
details = copy.deepcopy(self.UPDATE_MSG)
details['device_owner'] = 'network:dhcp'
details['device_owner'] = 'neutron:LOADBALANCER'
fdb_extension.handle_port(context=None, details=details)
updated_macs_for_device = (