From: Samuel Just Date: Sun, 1 Sep 2013 21:18:28 +0000 (-0700) Subject: ReplicatedPG/Backend: move over _failed_push X-Git-Tag: v0.71~68^2~19 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=c1c2debdb9240ea2cfe89e41e3af88af41176c48;p=ceph.git ReplicatedPG/Backend: move over _failed_push Signed-off-by: Samuel Just --- diff --git a/src/osd/ReplicatedBackend.h b/src/osd/ReplicatedBackend.h index e705bb9108c6..fa679a2069cd 100644 --- a/src/osd/ReplicatedBackend.h +++ b/src/osd/ReplicatedBackend.h @@ -228,7 +228,7 @@ private: bufferlist data_received, interval_set *intervals_usable, bufferlist *data_usable); - void _failed_push(int from, const hobject_t &soid) {} + void _failed_push(int from, const hobject_t &soid); void send_pushes(int prio, map > &pushes) {} void prep_push_op_blank(const hobject_t& soid, PushOp *op) {} diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index dd2755debee0..718a8ac1d5ed 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -6922,8 +6922,9 @@ void ReplicatedBackend::sub_op_push(OpRequestRef op) return; } -void ReplicatedPG::_failed_push(int from, const hobject_t &soid) +void ReplicatedPG::failed_push(int from, const hobject_t &soid) { + // TODOSAM: this will need to update recovering map >::iterator p = missing_loc.find(soid); if (p != missing_loc.end()) { dout(0) << "_failed_push " << soid << " from osd." << from @@ -6936,9 +6937,15 @@ void ReplicatedPG::_failed_push(int from, const hobject_t &soid) dout(0) << "_failed_push " << soid << " from osd." << from << " but not in missing_loc ???" << dendl; } - finish_recovery_op(soid); // close out this attempt, +} + +void ReplicatedBackend::_failed_push(int from, const hobject_t &soid) +{ + get_parent()->failed_push(from, soid); pull_from_peer[from].erase(soid); + if (pull_from_peer[from].empty()) + pull_from_peer.erase(from); pulling.erase(soid); } diff --git a/src/osd/ReplicatedPG.h b/src/osd/ReplicatedPG.h index fcbb2d58dc4d..80ffcc51029a 100644 --- a/src/osd/ReplicatedPG.h +++ b/src/osd/ReplicatedPG.h @@ -839,7 +839,6 @@ protected: void _applied_recovered_object_replica(); void _committed_pushed_object(epoch_t epoch, eversion_t lc); void recover_got(hobject_t oid, eversion_t v); - void _failed_push(int from, const hobject_t &soid); // -- copyfrom -- map copy_ops;