]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
osd/: condense missing mutations for recovery/repair/errors
authorSamuel Just <sjust@redhat.com>
Wed, 10 Apr 2019 02:29:05 +0000 (19:29 -0700)
committersjust@redhat.com <sjust@redhat.com>
Wed, 1 May 2019 18:22:28 +0000 (11:22 -0700)
commitd33a8b8ab1421802c876a324b8c91385b709be87
treefb354376c10506780b507ff5be7b5d4e59732206
parent5ea5c47152c798f5282f0203b5df74bf5de242e2
osd/: condense missing mutations for recovery/repair/errors

At a high level, this patch attempts to unify the various
sites at which some combination of
- mark object missing in one or more pg_missing_t
- mark object needs_recovery in missing_loc
- manipulate the locations map based on external information
occur.  It seems to me that the pg_missing_t and missing_loc
should be in sync except for the mark_unfound_lost_revert
case and the case where we are about to do a backfill push.

This patch also cleans up repair_object.  It sort of worked by accident
for non-ec non-primary bad peers.  It didn't update missing_loc, so
needs_recovery() returns the wrong answer.  However, is_unfound() does
as well, so ReplicatedBackend is nevertheless happy as the object would
be present on the primary.  This patch updates the behavior to be
uniform as in the other force_obejct_missing cases.

Signed-off-by: Samuel Just <sjust@redhat.com>
src/osd/MissingLoc.h
src/osd/PG.cc
src/osd/PG.h
src/osd/PeeringState.cc
src/osd/PeeringState.h
src/osd/PrimaryLogPG.cc
src/osd/PrimaryLogPG.h