From ac3270912b1deb41b914e9a683de25cd4d2d2337 Mon Sep 17 00:00:00 2001 From: Brandon Bordeaux Date: Thu, 2 Dec 2021 10:57:17 -0500 Subject: [PATCH] Relabel metric org.apache.cassandra.metrics.hints_service.hints_created.- to remove Peer IP from name and store the IP as a separate label. --- dashboards/prometheus/prometheus.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/dashboards/prometheus/prometheus.yaml b/dashboards/prometheus/prometheus.yaml index f676cb2..981d8ec 100644 --- a/dashboards/prometheus/prometheus.yaml +++ b/dashboards/prometheus/prometheus.yaml @@ -210,6 +210,14 @@ scrape_configs: regex: org\.apache\.cassandra\.metrics\.hints_service\.([^\-]+) target_label: __name__ replacement: mcac_hints_${1} + - source_labels: ["mcac"] + regex: org\.apache\.cassandra\.metrics\.hints_service\.hints_created\.([^\-]+) + target_label: peer_ip + replacement: ${1} + - source_labels: ["mcac"] + regex: org\.apache\.cassandra\.metrics\.hints_service\.hints_created\.([^\-]+) + target_label: __name__ + replacement: mcac_hints_created # Misc - source_labels: ["mcac"] regex: org\.apache\.cassandra\.metrics\.memtable_pool\.(\w+)