Comment 4 for bug 1721514

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (stable/pike)

Reviewed: https://review.openstack.org/509818
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=888482c9b4fb8a1bc23d4758301e319b7c5bc997
Submitter: Zuul
Branch: stable/pike

commit 888482c9b4fb8a1bc23d4758301e319b7c5bc997
Author: Balazs Gibizer <email address hidden>
Date: Thu Oct 5 14:01:35 2017 +0200

    fix unstable shelve offload functional tests

    The functional tests that are shelved offloaded instances and
    asserted that the resource allocation of the instance are
    freed were unstable. These tests only waited for the instance
    state to become SHELVED_OFFLOADED before checked the allocations.
    However the compute manager sets the instance state to
    SHELVED_OFFLOADED before deleting the allocations[1]. Therefore these
    tests were racy.

    With this patch the test will wait not only for the instance status to
    change but also for the instance host to be nulled as that happens
    after the resources are freed.

    [1] https://github.com/openstack/nova/blob/e4f89ed5dd4259188d020749fa8fb1c77be2c03a/nova/compute/manager.py#L4502-L4521

    Change-Id: Ibb90571907cafcb649284e4ea30810a307f1737e
    Closes-Bug: #1721514
    (cherry picked from commit b5dca17f74b7a789e16b78178ae5874a30f3e0da)