From 1a4993b4c815db228bbda18f18153056780a5397 Mon Sep 17 00:00:00 2001 From: jcountsNR <94138069+jcountsNR@users.noreply.github.com> Date: Thu, 21 Sep 2023 09:12:04 -0700 Subject: [PATCH] update to string instead of map --- .../kafkametricsreceiver/integration_test.go | 35 ++++++++++++------- 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/receiver/kafkametricsreceiver/integration_test.go b/receiver/kafkametricsreceiver/integration_test.go index 7af164eb04c3..e28a29978def 100644 --- a/receiver/kafkametricsreceiver/integration_test.go +++ b/receiver/kafkametricsreceiver/integration_test.go @@ -72,18 +72,29 @@ func TestIntegration(t *testing.T) { "consumers", "topics", } - rCfg.Metrics = map[string]bool{ - "messaging.kafka.broker.count": true, - "messaging.kafka.broker.consumer_fetch_rate": true, - "messaging.kafka.broker.incoming_byte_rate": true, - "messaging.kafka.broker.outgoing_byte_rate": true, - "messaging.kafka.broker.request_latency": true, - "messaging.kafka.broker.response_rate": true, - "messaging.kafka.broker.response_size": true, - "messaging.kafka.broker.request_rate": true, - "messaging.kafka.broker.request_size": true, - "messaging.kafka.broker.requests_in_flight": true, - "messaging.kafka.broker.consumer_fetch_count": true, + rCfg.Metrics = []string{ + "kafka.brokers", + "kafka.consumer_group.lag", + "kafka.consumer_group.lag_sum", + "kafka.consumer_group.members", + "kafka.consumer_group.offset", + "kafka.consumer_group.offset_sum", + "kafka.partition.current_offset", + "kafka.partition.oldest_offset", + "kafka.partition.replicas", + "kafka.partition.replicas_in_sync", + "kafka.topic.partitions", + "messaging.kafka.broker.consumer_fetch_count", + "messaging.kafka.broker.consumer_fetch_rate", + "messaging.kafka.broker.count", + "messaging.kafka.broker.incoming_byte_rate", + "messaging.kafka.broker.outgoing_byte_rate", + "messaging.kafka.broker.request_latency", + "messaging.kafka.broker.request_rate", + "messaging.kafka.broker.request_size", + "messaging.kafka.broker.requests_in_flight", + "messaging.kafka.broker.response_rate", + "messaging.kafka.broker.response_size", } }),