Pull out metric List build from metricstore Init

This commit is contained in:
2026-01-27 17:06:52 +01:00
parent 28a3ff8d67
commit 752e19c276
5 changed files with 58 additions and 140 deletions

View File

@@ -321,7 +321,8 @@ func runServer(ctx context.Context) error {
haveMetricstore := false
mscfg := ccconf.GetPackageConfig("metric-store")
if mscfg != nil {
metricstore.Init(mscfg, &wg)
metrics := metricstore.BuildMetricList()
metricstore.Init(mscfg, metrics, &wg)
// Inject repository as NodeProvider to break import cycle
ms := metricstore.GetMemoryStore()