Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Provide an online data migration to cleanup orphaned build requests
This exhibits the failure reported in bug 1633734 when upgrading from mitaka to newton with some bad build request records that weren't cleaned up, and were created before API DB migration 013_build_request_extended_attrs when we didn't have the instance_uuid or instance records in the database. After 013_build_request_extended_attrs and the object change to BuildRequest in a5d3b57 if we try loading up a 'dirty' build request DB record without the instance_uuid it fails with a ValueError, as shown in the functional test in this change. This also provides an online data migration (which will be backported to Newton for upgrades from Mitaka) that will query the API DB for build requests where instance_uuid=NULL and delete them. Change-Id: I8a05ee01ec7f6a6f88b896f78414fb5487e0071e Related-Bug: #1633734 (cherry picked from commit ab05b90)
- Loading branch information
Matt Riedemann
committed
Jan 4, 2017
1 parent
bfb5809
commit 608105a
Showing
3 changed files
with
137 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters