From a8eebf585023bdb4e592d17c9913c1176d5b1b3e Mon Sep 17 00:00:00 2001 From: Alexander Dejanovski Date: Tue, 24 Oct 2023 11:08:06 +0200 Subject: [PATCH] Fix namespace labelling on metrics in Vector remap operation --- pkg/telemetry/vector.go | 2 +- pkg/telemetry/vector_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/telemetry/vector.go b/pkg/telemetry/vector.go index b797da298..2e5e0acda 100644 --- a/pkg/telemetry/vector.go +++ b/pkg/telemetry/vector.go @@ -175,7 +175,7 @@ if err == null { Config: `source = ''' namespace, err = get_env_var("NAMESPACE") if err == null { - .namespace = namespace + .tags.namespace = namespace } ''' `, diff --git a/pkg/telemetry/vector_test.go b/pkg/telemetry/vector_test.go index 9bef3b06a..ef15f5b9e 100644 --- a/pkg/telemetry/vector_test.go +++ b/pkg/telemetry/vector_test.go @@ -231,7 +231,7 @@ inputs = ["cassandra_metrics_raw"] source = ''' namespace, err = get_env_var("NAMESPACE") if err == null { - .namespace = namespace + .tags.namespace = namespace } '''