From 1b00236749a91c6ea30606fd37b4369c0011a439 Mon Sep 17 00:00:00 2001 From: Lukasz Raczylo Date: Tue, 24 Nov 2026 02:42:11 +0000 Subject: [PATCH] test(gormstore): stop the background aggregator in time-series stores Rollup tests set the worker clock while the background aggregation loop read it, so the race detector failed about one run in ten. These stores now stop the loop, and the tests drive aggregation by hand. --- pkg/metadata/gormstore/timeseries_test.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkg/metadata/gormstore/timeseries_test.go b/pkg/metadata/gormstore/timeseries_test.go index 11a5901..0ea2b8a 100644 --- a/pkg/metadata/gormstore/timeseries_test.go +++ b/pkg/metadata/gormstore/timeseries_test.go @@ -28,6 +28,8 @@ func newTimeSeriesStore(t *testing.T) *GORMStoreV2 { LogLevel: "silent", }) require.NoError(t, err) + // Tests drive aggregation by hand and set the worker clock; the background loop would race that write. + store.aggregationWorker.Stop() return store }