Address infinite loop in nova compute when getting network info
Move the refresh_cache decorator to get_instance_nw_info.
In fact, _get_instance_nw_info is called by the decorator
itself, potentially causing an infinite loop in case nw_info
is not of the expected value. This is also inline with
the method's purpose, as stated by the docstring. At the
same time, ensure that delete_port_for_instance and
allocate_for_instance continue to refresh the cache by
using the decorated version.
Also, add a couple of debug traces that are friendly to
the developer.
Partial-bug: 1235435
Related-bug: 1251792
Change-Id: I06f8634ea241d05ac8fbcc290adf0cb23829f3e4
(cherry picked from commit 2e520496c369a8ef646820ec068cc4416ab50eca)
Reviewed: https:/ /review. openstack. org/58471 github. com/openstack/ nova/commit/ ef9aec1cb6ec0d5 fae699f9bb1f0d0 42530de5de
Committed: http://
Submitter: Jenkins
Branch: stable/havana
commit ef9aec1cb6ec0d5 fae699f9bb1f0d0 42530de5de
Author: armando-migliaccio <email address hidden>
Date: Mon Nov 18 16:10:48 2013 -0800
Address infinite loop in nova compute when getting network info
Move the refresh_cache decorator to get_instance_ nw_info. nw_info is called by the decorator port_for_ instance and for_instance continue to refresh the cache by
In fact, _get_instance_
itself, potentially causing an infinite loop in case nw_info
is not of the expected value. This is also inline with
the method's purpose, as stated by the docstring. At the
same time, ensure that delete_
allocate_
using the decorated version.
Also, add a couple of debug traces that are friendly to
the developer.
Partial-bug: 1235435
Related-bug: 1251792
Change-Id: I06f8634ea241d0 5ac8fbcc290adf0 cb23829f3e4 f646820ec068cc4 416ab50eca)
(cherry picked from commit 2e520496c369a8e