From 430b38df0ed28ffbfba54afb0d7c94a06bffa1ae Mon Sep 17 00:00:00 2001 From: Vishal Raj Date: Wed, 19 Jun 2024 09:44:20 +0100 Subject: [PATCH] Enable k8s otel metrics remapping to elastic metrics (#296) --- input/otlp/consumer.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/input/otlp/consumer.go b/input/otlp/consumer.go index b1c3e3e8..87c422c9 100644 --- a/input/otlp/consumer.go +++ b/input/otlp/consumer.go @@ -23,6 +23,7 @@ import ( "github.com/elastic/apm-data/input" "github.com/elastic/apm-data/model/modelpb" "github.com/elastic/opentelemetry-lib/remappers/hostmetrics" + "github.com/elastic/opentelemetry-lib/remappers/kubernetesmetrics" "go.opentelemetry.io/collector/consumer" "go.opentelemetry.io/collector/pdata/pcommon" "go.opentelemetry.io/collector/pdata/pmetric" @@ -72,6 +73,7 @@ func NewConsumer(config ConsumerConfig) *Consumer { if config.RemapOTelMetrics { remappers = []remapper{ hostmetrics.NewRemapper(config.Logger), + kubernetesmetrics.NewRemapper(config.Logger), } } return &Consumer{