From 4269107514aa1dd40e828c0e16010ecc2be3b74c Mon Sep 17 00:00:00 2001 From: cserwen Date: Tue, 17 May 2022 10:38:53 +0800 Subject: [PATCH] remove lastupdateTimestamp for offset metric --- .../exporter/collector/RMQMetricsCollector.java | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/main/java/org/apache/rocketmq/exporter/collector/RMQMetricsCollector.java b/src/main/java/org/apache/rocketmq/exporter/collector/RMQMetricsCollector.java index ae87541..a233065 100644 --- a/src/main/java/org/apache/rocketmq/exporter/collector/RMQMetricsCollector.java +++ b/src/main/java/org/apache/rocketmq/exporter/collector/RMQMetricsCollector.java @@ -315,11 +315,11 @@ private void collectConsumerMetric(List mfs) { private static final List TOPIC_OFFSET_LABEL_NAMES = Arrays.asList( - "cluster", "broker", "topic", "lastUpdateTimestamp" + "cluster", "broker", "topic" ); private static final List DLQ_TOPIC_OFFSET_LABEL_NAMES = Arrays.asList( - "cluster", "broker", "group", "lastUpdateTimestamp" + "cluster", "broker", "group" ); private void loadTopicOffsetMetric(GaugeMetricFamily family, Map.Entry entry) { @@ -327,8 +327,7 @@ private void loadTopicOffsetMetric(GaugeMetricFamily family, Map.Entry mfs) { Arrays.asList( entry.getKey().getClusterName(), entry.getKey().getBrokerName(), - entry.getKey().getGroup(), - String.valueOf(entry.getKey().getLastUpdateTimestamp()) + entry.getKey().getGroup() ), entry.getValue()); }