Bug #1707669 highlighted a situation that arose when attempting to
remove part of an allocation for a source host during a resize
operation where the exiting allocation was not being properly deleted.
In this patch, we remove the part of the WHERE condition that limited
deleted allocation records to only those referring to a particular
resource provider. In doing so, we make the creation of an allocation
for a consumer a proper overwrite operation.
Reviewed: https:/ /review. openstack. org/490231 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=9f4db205bbb b215e77741df229 79a20d62d80ae8
Committed: https:/
Submitter: Jenkins
Branch: stable/ocata
commit 9f4db205bbbb215 e77741df22979a2 0d62d80ae8
Author: Jay Pipes <email address hidden>
Date: Mon Jul 31 12:28:38 2017 -0400
placement: remove existing allocs when set allocs
Bug #1707669 highlighted a situation that arose when attempting to
remove part of an allocation for a source host during a resize
operation where the exiting allocation was not being properly deleted.
In this patch, we remove the part of the WHERE condition that limited
deleted allocation records to only those referring to a particular
resource provider. In doing so, we make the creation of an allocation
for a consumer a proper overwrite operation.
Conflicts:
nova/ objects/ resource_ provider. py
nova/ tests/functiona l/db/test_ resource_ provider. py
NOTE(mriedem): The conflicts are both due to changes in Pike that
aren't needed here:
a90967368 2cdd8f02ef0ae5e 8c6f061640e320f f added user/project to allocations
86fe9a70c 24fce71bf85bfe3 9917073f833a095 1 renamed context to ctx in tests
Change-Id: I0835e5b4f22277 465012aab9a5bf4 74608cb533b b8d6d8646f408e9 522596870e)
Fixes-bug: #1707669
(cherry picked from commit afab0ca0c8f4c68