yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #67854
[Bug 1717365] Re: binding:profile is None breaks migration
Reviewed: https://review.openstack.org/504260
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=8ac7be36bedaf0dd3467efc5b5bffdb365b8231b
Submitter: Jenkins
Branch: master
commit 8ac7be36bedaf0dd3467efc5b5bffdb365b8231b
Author: Matt Riedemann <mriedem.os@xxxxxxxxx>
Date: Thu Sep 14 18:04:20 2017 -0400
neutron: handle binding:profile=None during migration
The port binding:profile handling in _setup_migration_port_profile
and _update_port_binding_for_instance is not handling when the
binding:profile is set on the port but the value is None, which
results in a NoneType error. Neutron API does not define a format
for this field, or whether or not it will be specified on the port,
and if so, if it's an empty dict or None, so let's be safe and
make sure we handle None.
Because of how many places we access the binding:profile on
a port, this adds a common helper utility.
Co-Authored-By: Eric M Gonzalez <eric@xxxxxxxxx>
Change-Id: I564bac88fad6cc47ccbf7425b1ab39899fdc1c2e
Closes-Bug: #1717365
** Changed in: nova
Status: In Progress => Fix Released
** Changed in: nova/pike
Status: Confirmed => In Progress
** Changed in: nova/pike
Assignee: (unassigned) => Matt Riedemann (mriedem)
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1717365
Title:
binding:profile is None breaks migration
Status in OpenStack Compute (nova):
Fix Released
Status in OpenStack Compute (nova) newton series:
Confirmed
Status in OpenStack Compute (nova) ocata series:
In Progress
Status in OpenStack Compute (nova) pike series:
In Progress
Bug description:
Nova Newton (commit: d8b30c3772 as pulled in with OSA 14.2.7)
During a live-migration, setup_networks_at_host tries to lookup some
information from the network port.
at
https://review.openstack.org/#/c/275073/45/nova/network/neutronv2/api.py@289
If the port has None assigned to "binding:profile" further code breaks
with a TypeError assigning to NoneType.
mriedem suggested catching this with an extended .get():
16:27 < mriedem> since the port_profile should default to {}, UNLESS the port has binding:profile=None...
16:27 < mriedem> it should be: port_profile = p.get(BINDING_PROFILE, {}) or {}
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1717365/+subscriptions
References