The keypair of a server is updated when rebuilding the server with a
keypair. This function has been added since API microversion 2.54.
However the 'keypairs' of the instance object is not saved when saving
the instance object currently.
Make the instance object update the 'keypairs' field when saving the
instance object.
Conflicts: nova/tests/unit/fake_instance.py
NOTE(stephenfin): Conflicts are due to change
I44ad826f0edb39d770bb3201c675dff78154cbf3 ("partial support for live
migration with specific resources"), which initialized the
'migration_context' attribute of the instance created as part of the
'fake_instance_obj' function.
NOTE(stephenfin): The 'IntegratedTestBase' and 'InstanceHelperMixin'
base classes for functional tests are not fully integrated yet in
stable/train, which requires reinventing the wheel somewhat.
Change-Id: I8a2726b39d0444de8c35480024078a97430f5d0c
Closes-Bug: #1843708
Co-authored-by: Stephen Finucane <email address hidden>
(cherry picked from commit 086796021b189c3ac64805ed8f6bde833906d284)
(cherry picked from commit aed86ee5d6289edf1baf9fe0b2a9e509031fdd25)
Reviewed: https:/ /review. opendev. org/742709 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=b971dc82cb5 24fe86284c95ec6 71e2bad1c2874f
Committed: https:/
Submitter: Zuul
Branch: stable/train
commit b971dc82cb524fe 86284c95ec671e2 bad1c2874f
Author: Takashi NATSUME <email address hidden>
Date: Thu Sep 19 15:57:44 2019 +0900
objects: Update keypairs when saving an instance
The keypair of a server is updated when rebuilding the server with a
keypair. This function has been added since API microversion 2.54.
However the 'keypairs' of the instance object is not saved when saving
the instance object currently.
Make the instance object update the 'keypairs' field when saving the
instance object.
Conflicts:
nova/ tests/unit/ fake_instance. py
NOTE( stephenfin) : Conflicts are due to change db39d770bb3201c 675dff78154cbf3 ("partial support for live context' attribute of the instance created as part of the instance_ obj' function.
I44ad826f0e
migration with specific resources"), which initialized the
'migration_
'fake_
Changes:
nova/ tests/functiona l/regressions/ test_bug_ 1843708. py
NOTE( stephenfin) : The 'IntegratedTest Base' and 'InstanceHelper Mixin'
base classes for functional tests are not fully integrated yet in
stable/train, which requires reinventing the wheel somewhat.
Change-Id: I8a2726b39d0444 de8c35480024078 a97430f5d0c ac64805ed8f6bde 833906d284) f1baf9fe0b2a9e5 09031fdd25)
Closes-Bug: #1843708
Co-authored-by: Stephen Finucane <email address hidden>
(cherry picked from commit 086796021b189c3
(cherry picked from commit aed86ee5d6289ed