Validate volume status again when snapshot created
In a multitask environment, the volume can be deleted
after the snapshot record is created. Add the validation
right after the creation to avoid undeletable snapshot.
Closes-Bug: #1739995
Change-Id: Icbe86473243871996483fdc96c079b8861bac2e5
(cherry picked from commit 7ccfb2c8d94824321d4bfca7266c5d72674c061f)
Conflicts:
cinder/tests/unit/api/v3/test_snapshots.py
cinder/tests/unit/volume/test_volume.py
Reviewed: https:/ /review. openstack. org/530964 /git.openstack. org/cgit/ openstack/ cinder/ commit/ ?id=78cd77edef1 a08f0472b8df040 9adebb9b12e865
Committed: https:/
Submitter: Zuul
Branch: stable/pike
commit 78cd77edef1a08f 0472b8df0409ade bb9b12e865
Author: TommyLike <email address hidden>
Date: Mon Dec 25 09:19:20 2017 +0800
Validate volume status again when snapshot created
In a multitask environment, the volume can be deleted
after the snapshot record is created. Add the validation
right after the creation to avoid undeletable snapshot.
Closes-Bug: #1739995
Change-Id: Icbe86473243871 996483fdc96c079 b8861bac2e5 21d4bfca7266c5d 72674c061f) tests/unit/ api/v3/ test_snapshots. py tests/unit/ volume/ test_volume. py
(cherry picked from commit 7ccfb2c8d948243
Conflicts:
cinder/
cinder/