Comment 17 for bug 1670627

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

Reviewed: https://review.openstack.org/443395
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=018068c4caac324643c7c6a4360fad855dd096eb
Submitter: Jenkins
Branch: master

commit 018068c4caac324643c7c6a4360fad855dd096eb
Author: Matt Riedemann <email address hidden>
Date: Wed Mar 8 21:51:07 2017 -0500

    Decrement quota usage when deleting an instance in cell0

    When we fail to schedule an instance, e.g. there are no hosts
    available, conductor creates the instance in the cell0 database
    and deletes the build request. At this point quota usage
    has been incremented in the main 'nova' database.

    When the instance is deleted, the build request is already gone
    so _delete_while_booting returns False and we lookup the instance
    in cell0 and delete it from there, but that flow wasn't decrementing
    quota usage like _delete_while_booting was.

    This change adds the same quota usage decrement handling that
    _delete_while_booting performs.

    Change-Id: I4cb0169ce0de537804ab9129bc671d75ce5f7953
    Partial-Bug: #1670627