]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commit
Remove API races from delete methods
authorGorka Eguileor <geguileo@redhat.com>
Fri, 21 Aug 2015 17:55:22 +0000 (19:55 +0200)
committerGorka Eguileor <geguileo@redhat.com>
Wed, 23 Dec 2015 13:33:38 +0000 (14:33 +0100)
commit22b430025306a225fd965d5b5afdbc0ddd415add
treed7f80208806d5e360b8f2574fb9793213fe7b40a
parentc7bfd636b32cfeebeb45135a6aedcd8e9214ca11
Remove API races from delete methods

This patch changes delete API methods to use compare-and-swap updates in
order to remove potential races.

Updated methods are:
- delete
- delete_snapshot

Specs: https://review.openstack.org/232599/

Implements: blueprint cinder-volume-active-active-support
Closes-Bug: #1490944
Change-Id: Ic09825b27774fa4b0ab2b7e60577ecfb3640bcf2
cinder/api/contrib/volume_unmanage.py
cinder/api/v2/volumes.py
cinder/db/api.py
cinder/db/sqlalchemy/api.py
cinder/tests/unit/api/contrib/test_snapshot_unmanage.py
cinder/tests/unit/api/contrib/test_volume_unmanage.py
cinder/tests/unit/api/v2/test_volumes.py
cinder/tests/unit/test_volume.py
cinder/volume/api.py