From 90d793e8c5e8f8c9823cfa9942e4e08019b37a6d Mon Sep 17 00:00:00 2001 From: Bryan Boreham Date: Mon, 22 Jul 2024 15:33:07 +0100 Subject: [PATCH] [BUGFIX] Storage: Single secondary querier errors should be warnings. Signed-off-by: Bryan Boreham --- storage/merge.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/storage/merge.go b/storage/merge.go index 194494b6a..66c4c3ed3 100644 --- a/storage/merge.go +++ b/storage/merge.go @@ -51,7 +51,7 @@ func NewMergeQuerier(primaries, secondaries []Querier, mergeFn VerticalSeriesMer case len(primaries) == 1 && len(secondaries) == 0: return primaries[0] case len(primaries) == 0 && len(secondaries) == 1: - return secondaries[0] + return &querierAdapter{newSecondaryQuerierFrom(secondaries[0])} } queriers := make([]genericQuerier, 0, len(primaries)+len(secondaries)) @@ -89,7 +89,7 @@ func NewMergeChunkQuerier(primaries, secondaries []ChunkQuerier, mergeFn Vertica case len(primaries) == 1 && len(secondaries) == 0: return primaries[0] case len(primaries) == 0 && len(secondaries) == 1: - return secondaries[0] + return &chunkQuerierAdapter{newSecondaryQuerierFromChunk(secondaries[0])} } queriers := make([]genericQuerier, 0, len(primaries)+len(secondaries))