commit 22adc624666e5cc94fb533d95c998f59c70d5890
Author: Dan Smith <email address hidden>
Date: Mon Jun 1 07:31:26 2015 -0700
Make nova-manage handle completely missing flavor information
If you have a really (really) old instance without any flavor information
stashed in sysmeta, then nova-manage will not be able to convert it to
a proper flavor object in extra. This patch makes it handle that case
by looking up the flavor by id instead. Not only will this facilitate
the transition, but will also ensure that any such legacy instances are
properly brought up to date so that going forward we can just assume that
they have all been converted (and remove some other places where we
handle the has-no-flavor-info case).
This involves changing the flavor cache to contain flavor objects
instead of DB objects so that the two methods that use the cache can
coexist. It doesn't much affect the _augment_flavors_to_migrate() path,
other than some mechanics and test changes.
Conflicts:
nova/tests/unit/db/test_db_api.py
Change-Id: I54a056d339d98bc4092af8cf9f4f5d24b882506b
Closes-Bug: #1460673
(cherry picked from commit 240fb9c5392f71e59e6ef2f8f917b098f1cf9960)
Reviewed: https:/ /review. openstack. org/187740 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=22adc624666 e5cc94fb533d95c 998f59c70d5890
Committed: https:/
Submitter: Jenkins
Branch: stable/kilo
commit 22adc624666e5cc 94fb533d95c998f 59c70d5890
Author: Dan Smith <email address hidden>
Date: Mon Jun 1 07:31:26 2015 -0700
Make nova-manage handle completely missing flavor information
If you have a really (really) old instance without any flavor information
stashed in sysmeta, then nova-manage will not be able to convert it to
a proper flavor object in extra. This patch makes it handle that case
by looking up the flavor by id instead. Not only will this facilitate
the transition, but will also ensure that any such legacy instances are
properly brought up to date so that going forward we can just assume that
they have all been converted (and remove some other places where we
handle the has-no-flavor-info case).
This involves changing the flavor cache to contain flavor objects flavors_ to_migrate( ) path,
instead of DB objects so that the two methods that use the cache can
coexist. It doesn't much affect the _augment_
other than some mechanics and test changes.
Conflicts: tests/unit/ db/test_ db_api. py
nova/
Change-Id: I54a056d339d98b c4092af8cf9f4f5 d24b882506b 59e6ef2f8f917b0 98f1cf9960)
Closes-Bug: #1460673
(cherry picked from commit 240fb9c5392f71e