From bb377a3544d03e5339c60c104bafba12503f7f78 Mon Sep 17 00:00:00 2001 From: Joonas Koivunen Date: Thu, 25 Jul 2024 12:24:38 +0000 Subject: [PATCH] fixup: make sure detach_ancestor is blocking gc --- pageserver/src/tenant/timeline/detach_ancestor.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pageserver/src/tenant/timeline/detach_ancestor.rs b/pageserver/src/tenant/timeline/detach_ancestor.rs index 654237e0b0..3e39ccf885 100644 --- a/pageserver/src/tenant/timeline/detach_ancestor.rs +++ b/pageserver/src/tenant/timeline/detach_ancestor.rs @@ -579,7 +579,11 @@ impl SharedStateBuilder { timeline_id: &TimelineId, index_part: &crate::tenant::IndexPart, ) { - if index_part.gc_blocking.is_some() { + if index_part + .gc_blocking + .as_ref() + .is_some_and(|b| b.blocked_by_detach_ancestor()) + { // if the loading a timeline fails, tenant loading must fail as it does right now, or // something more elaborate needs to be done with this tracking self.inprogress.insert(*timeline_id);