From 852d7b5b3c019c02c042b767fc88916088e1a94d Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Thu, 8 Jan 2015 11:17:03 -0800 Subject: [PATCH] osd: requeue PG when we skip handling a peering event If we don't handle the event, we need to put the PG back into the peering queue or else the event won't get processed until the next event is queued, at which point we'll be processing events with a delay. The queue_null is not necessary (and is a waste of effort) because the event is still in pg->peering_queue and the PG is queued. This is a firefly-specific patch; a (very) similar one will appear in master in 492ccc900c3358f36b6b14a207beec071eb06707. Backport: giant, firefly Signed-off-by: Sage Weil --- src/osd/OSD.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/osd/OSD.cc b/src/osd/OSD.cc index 586b7d707b644..77ed17aed027c 100644 --- a/src/osd/OSD.cc +++ b/src/osd/OSD.cc @@ -7858,7 +7858,9 @@ void OSD::process_peering_events( continue; } if (!advance_pg(curmap->get_epoch(), pg, handle, &rctx, &split_pgs)) { - pg->queue_null(curmap->get_epoch(), curmap->get_epoch()); + // we need to requeue the PG explicitly since we didn't actually + // handle an event + peering_wq.queue(pg); } else if (!pg->peering_queue.empty()) { PG::CephPeeringEvtRef evt = pg->peering_queue.front(); pg->peering_queue.pop_front(); -- 2.39.5