Fix incorrect enum in Migration object and DB model

The migration object and model incorrectly mirrored the migration_type
enum from the database schema. Since the affected type (evacuation) has
never been used before this change, we can just make the swap with no
version bump.

Related to blueprint robustify-evacuation

Change-Id: If502903fecd315e24c987da6d78b73dcc1305ee3
This commit is contained in:
Dan Smith 2015-07-06 15:22:12 -07:00
parent 74197aaa3f
commit 91da50d0c7
3 changed files with 3 additions and 3 deletions

View File

@ -742,7 +742,7 @@ class Migration(BASE, NovaBase):
# TODO(_cerberus_): enum
status = Column(String(255))
migration_type = Column(Enum('migration', 'resize', 'live-migration',
'evacuate'),
'evacuation'),
nullable=True)
hidden = Column(Boolean, default=False)

View File

@ -48,7 +48,7 @@ class Migration(base.NovaPersistentObject, base.NovaObject,
'instance_uuid': fields.StringField(nullable=True),
'status': fields.StringField(nullable=True),
'migration_type': fields.EnumField(['migration', 'resize',
'live-migration', 'evacuate'],
'live-migration', 'evacuation'],
nullable=False),
'hidden': fields.BooleanField(nullable=False, default=False),
}

View File

@ -1099,7 +1099,7 @@ object_data = {
'InstancePCIRequests': '1.1-fc8d179960869c9af038205a80af2541',
'KeyPair': '1.3-bfaa2a8b148cdf11e0c72435d9dd097a',
'KeyPairList': '1.2-60f984184dc5a8eba6e34e20cbabef04',
'Migration': '1.2-331b1f37d0b20b932614181b9832c860',
'Migration': '1.2-8784125bedcea0a9227318511904e853',
'MigrationList': '1.2-5e79c0693d7ebe4e9ac03b5db11ab243',
'NUMACell': '1.2-74fc993ac5c83005e76e34e8487f1c05',
'NUMAPagesTopology': '1.0-c71d86317283266dc8364c149155e48e',