]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
librbd: wait for journal commit op event to be safely recorded
authorJason Dillaman <dillaman@redhat.com>
Tue, 19 Jul 2016 04:42:16 +0000 (00:42 -0400)
committerJason Dillaman <dillaman@redhat.com>
Wed, 17 Aug 2016 17:22:05 +0000 (13:22 -0400)
commit99195e89e4d229922c6e88aed6a024619e939040
tree9aeb9d4180de7e3a1546167fe4d2eb46235142bd
parent3ae52ebadb5ef0de63ba30f937dcbcad507a7048
librbd: wait for journal commit op event to be safely recorded

Operation request op finish events should not be fire and forget.
Instead, ensure the event is committed to the journal before
completing the op. This will avoid several possible split-brain
events during mirroring.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 47e0fbf231e52d00069c97b72c57c3158445bcf0)

Conflicts:
src/test/librbd/operation/test_mock_ResizeRequest.cc: no shrink restriction
12 files changed:
src/librbd/AsyncRequest.h
src/librbd/Journal.cc
src/librbd/Journal.h
src/librbd/operation/Request.cc
src/librbd/operation/Request.h
src/librbd/operation/ResizeRequest.cc
src/librbd/operation/SnapshotCreateRequest.cc
src/librbd/operation/SnapshotCreateRequest.h
src/librbd/operation/SnapshotRollbackRequest.cc
src/test/librbd/mock/MockJournal.h
src/test/librbd/operation/test_mock_ResizeRequest.cc
src/test/librbd/test_mock_fixture.cc