commit 26c593c91f008caab92ed52156dfe2d898955d3f
Author: Eric Fried <email address hidden>
Date: Tue Jan 30 21:53:52 2018 -0600
Avoid inventory DELETE API (no conflict detection)
SchedulerReportClient._delete_inventory used the DELETE
/resource_providers/{u}/inventories API, which does not provide a way to
send the generation down (see bug 1746373), and is therefore subject to
concurrency errors.
This change set removes the _delete_inventory method and uses PUT
/resource_providers/{u}/inventories with an empty 'inventories' dict
instead, because that API *does* take the generation in the payload.
Doing this makes moot part of bug 1746075 by removing one of the code
paths that exploits undocumented knowledge of how placement uses the
generation counter.
Reviewed: https:/ /review. openstack. org/539712 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=26c593c91f0 08caab92ed52156 dfe2d898955d3f
Committed: https:/
Submitter: Zuul
Branch: master
commit 26c593c91f008ca ab92ed52156dfe2 d898955d3f
Author: Eric Fried <email address hidden>
Date: Tue Jan 30 21:53:52 2018 -0600
Avoid inventory DELETE API (no conflict detection)
SchedulerRe portClient. _delete_ inventory used the DELETE providers/ {u}/inventories API, which does not provide a way to
/resource_
send the generation down (see bug 1746373), and is therefore subject to
concurrency errors.
This change set removes the _delete_inventory method and uses PUT providers/ {u}/inventories with an empty 'inventories' dict
/resource_
instead, because that API *does* take the generation in the payload.
Doing this makes moot part of bug 1746075 by removing one of the code
paths that exploits undocumented knowledge of how placement uses the
generation counter.
Change-Id: Ia8131b32debd56 b28315ef430ee4e 8888b6f56e7
Closes-Bug: #1746374
Related-Bug: #1746373
Related-Bug: #1746075