Merge "Set right attach mode after migration"

This commit is contained in:
Zuul 2018-11-27 10:40:01 +00:00 committed by Gerrit Code Review
commit c7c48fd15c
2 changed files with 2 additions and 2 deletions

View File

@ -642,7 +642,7 @@ class VolumeMigrationTestCase(base.BaseVolumeTestCase):
attachment['instance_uuid'],
attachment['attached_host'],
attachment['mountpoint'],
'rw'
attachment.get('attach_mode', 'rw'),
)
self.assertIsNotNone(attachments)
self.assertEqual(attached_host,

View File

@ -2319,7 +2319,7 @@ class VolumeManager(manager.CleanableManager,
attachment.instance_uuid,
attachment.attached_host,
attachment.mountpoint,
'rw')
attachment.attach_mode or 'rw')
# At this point we now have done almost all of our swapping and
# state-changes. The target volume is now marked back to
# "in-use" the destination/worker volume is now in deleting