neutron/neutron/plugins/ml2/drivers/macvtap/mech_driver
Kevin Benton fe3a2139a8 Macvtap: Check for no original port in is_live_migration
Change 6865f4d9f2 mistakenly
assumed that None would not be present for the 'original'
property on a PortContext. However, this is the default value
for the original field in PortContext, which is what is used
in the construction as part of the _create_port_db process
in ML2.

This resulted in binding failures for the macvtap mech drivers
due to an attribute error in cases like brand new ports.

This patch simply checks for None before trying to determine
if it's a live migration (which it isn't in the case of port creation).

Part of the issue is likely that the FakePortContext in the unit tests
was defaulting to an empty dict which is the not the same behavior as
the real PortContext.

Change-Id: I6659235a70aa4528fd21911c04e651194591e449
Closes-Bug: #1658802
(cherry picked from commit 3dddfa56db)
2017-06-02 09:16:03 +00:00
..
__init__.py macvtap: ML2 mech driver for macvtap network attachments 2016-02-17 15:57:37 +01:00
mech_macvtap.py Macvtap: Check for no original port in is_live_migration 2017-06-02 09:16:03 +00:00