PG: check_recovery_sources on each map

Signed-off-by: Samuel Just <sam.just@inktank.com>
This commit is contained in:
Samuel Just 2012-06-20 09:29:18 -07:00
parent fb4ce53865
commit 090e5109f2

View File

@ -4162,6 +4162,7 @@ boost::statechart::result PG::RecoveryState::Active::react(const AdvMap& advmap)
dout(10) << *pg << " snap_trimq now " << pg->snap_trimq << dendl;
pg->dirty_info = true;
}
pg->check_recovery_sources(pg->get_osdmap());
return forward_event();
}
@ -4172,8 +4173,7 @@ boost::statechart::result PG::RecoveryState::Active::react(const ActMap&)
assert(pg->is_active());
assert(pg->is_primary());
if (pg->check_recovery_sources(pg->get_osdmap()) &&
pg->have_unfound()) {
if (pg->have_unfound()) {
// object may have become unfound
pg->discover_all_missing(*context< RecoveryMachine >().get_query_map());
}