]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
os/FileJournal: fix journal completion plug removal
authorSage Weil <sage@inktank.com>
Tue, 16 Apr 2013 15:26:47 +0000 (08:26 -0700)
committerSamuel Just <sam.just@inktank.com>
Tue, 16 Apr 2013 20:20:58 +0000 (13:20 -0700)
commit02d3c114ab869b0ddc4d26c68e8b9e3391e7ad1b
treea6de41d50c474c9e79213b6ee1205a2b422d90ec
parent4a84ddbd30ef3cc105053f272819c2f1ea2be0d2
os/FileJournal: fix journal completion plug removal

We plug completions when transitioning from a full to non-full journal
to ensure that we do not complete items before we have a stable journal
starting point that is past the committed_thru marker.  However, the order
of the header update and completion queueing means that we never remove
the plug if the journalq is empty--the seq test is always false.  The
result is very slow osd requests that only commit when we do a full sync.

This bug was masked until recently by another issue, fixed in
170d4a3d794260476ecde1e5e2ee719b7cb3ffd1.

The simple fix is to reorder the completion queuing before we update the
new header.

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Samuel Just <sam.just@inktank.com>
src/os/FileJournal.cc