]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
osd/: cleanup the snap trimmer and deal with delayed repops
authorSamuel Just <sjust@redhat.com>
Fri, 21 Oct 2016 21:29:09 +0000 (14:29 -0700)
committerSamuel Just <sjust@redhat.com>
Thu, 17 Nov 2016 18:41:34 +0000 (10:41 -0800)
commit407eaaca324fd5f57ff621d999c507cc5ddccdfc
treeffe609cadb5f67f2537c9e08b6921ac6c738da81
parent327dd257d3aacc50c560a34cf6e3f61111813ba8
osd/: cleanup the snap trimmer and deal with delayed repops

With the PGBackend changes, it's not necessarily the case that
calling simple_opc_submit syncronously updates the SnapMapper.
Thus, we can't rely on being able to just ask the snap mapper
for the next object immediately (we could well loop on the same
one if ECBackend is flushing the pipeline).  Instead, update
SnapMapper and the SnapTrimmer to grab N at a time.

Additionally, we need to make sure we don't try this again until
all of the previously submitted repops are flushed (a good idea
anyway).  To that end, this patch also refactors the SnapTrimmer
machine to be fully explicit about why it's blocked so we can be
sure that we don't queue an async work item unless we really
want to.

Signed-off-by: Samuel Just <sjust@redhat.com>
src/osd/OSD.cc
src/osd/OSD.h
src/osd/PG.cc
src/osd/PG.h
src/osd/ReplicatedPG.cc
src/osd/ReplicatedPG.h
src/osd/SnapMapper.cc
src/osd/SnapMapper.h
src/osd/osd_types.h
src/test/test_snap_mapper.cc