Comment 3 for bug 1746075

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to nova (master)

Reviewed: https://review.openstack.org/539712
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=26c593c91f008caab92ed52156dfe2d898955d3f
Submitter: Zuul
Branch: master

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.

    Change-Id: Ia8131b32debd56b28315ef430ee4e8888b6f56e7
    Closes-Bug: #1746374
    Related-Bug: #1746373
    Related-Bug: #1746075