Backup stacks should be hard-deleted

Bug #1332300 reported by Zane Bitter
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Heat
Triaged
Medium
Unassigned

Bug Description

During a stack update, we create a "backup" stack in which we temporarily store resources we are expecting to delete later while their replacements are created. Due to the fact that stacks are only soft-deleted, the backup stack, its template, and any associated resources are not removed from the DB when the update completes successfully. (They will be removed when the operator does a periodic clean-out of deleted stacks.)

This is both a waste of DB space and could cause potentially cause problems (in _theory_ it's OK...) on a future update due to the out-of-date template & resources. We should probably do a hard delete of the backup stack on conclusion of a successful stack update.

Zane Bitter (zaneb)
Changed in heat:
status: New → Triaged
importance: Undecided → Medium
Anant Patil (ananta)
Changed in heat:
assignee: nobody → Anant Patil (anant-techie)
Revision history for this message
Anant Patil (ananta) wrote :

Is there a particular test case which failed for you? I did a simple test where I had only VMs as resources and when I update the stack, the old resources (VMs) are deleted.

Revision history for this message
Pavlo Shchelokovskyy (pshchelo) wrote :

IMO this is not about actual resources, but about a stack object and it's representation in the Heat database. The change should be somewhere around this

https://github.com/openstack/heat/blob/master/heat/engine/parser.py#L672

Anant Patil (ananta)
Changed in heat:
status: Triaged → In Progress
Steven Hardy (shardy)
Changed in heat:
milestone: none → juno-3
Thierry Carrez (ttx)
Changed in heat:
milestone: juno-3 → juno-rc1
Zane Bitter (zaneb)
Changed in heat:
milestone: juno-rc1 → next
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to heat (master)

Reviewed: https://review.openstack.org/111986
Committed: https://git.openstack.org/cgit/openstack/heat/commit/?id=7cf6e52cacd2382b44b9255e9a5ed13271841261
Submitter: Jenkins
Branch: master

commit 7cf6e52cacd2382b44b9255e9a5ed13271841261
Author: ananta <email address hidden>
Date: Tue Aug 5 17:07:25 2014 +0530

    Hard delete backup stack after successful update.

    After successful update of a stack, the backup stack and it's associated
    template, resources and events should be permanently deleted.

    Closes-Bug: #1332300

    Change-Id: I3a462690b5f6bfadfbcf16eeb6bdec7c5ece2e83

Changed in heat:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in heat:
milestone: next → none
Revision history for this message
Zane Bitter (zaneb) wrote :

Reopening since we had to revert the fix: https://review.openstack.org/#/c/126084/

Changed in heat:
status: Fix Committed → Triaged
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to heat (master)

Fix proposed to branch: master
Review: https://review.openstack.org/128918

Changed in heat:
status: Triaged → In Progress
Changed in heat:
assignee: Anant Patil (ananta) → Ishant Tyagi (ishant-tyagi)
Changed in heat:
assignee: Ishant Tyagi (ishant-tyagi) → Rakesh H S (rh-s)
Rakesh H S (rh-s)
Changed in heat:
assignee: Rakesh H S (rh-s) → nobody
Changed in heat:
status: In Progress → Triaged
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on heat (master)

Change abandoned by Anant Patil (<email address hidden>) on branch: master
Review: https://review.openstack.org/128918

Rico Lin (rico-lin)
Changed in heat:
milestone: none → no-priority-tag-bugs
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.