From 22fbc85c51fb3ca7c71236dc3e89f9414a02f2d4 Mon Sep 17 00:00:00 2001 From: Miles-Garnsey Date: Fri, 17 Feb 2023 20:05:29 +1100 Subject: [PATCH] Fix tests. --- .../cassandra_agent_config_test.go | 53 +++++++++---------- 1 file changed, 24 insertions(+), 29 deletions(-) diff --git a/pkg/telemetry/cassandra_agent/cassandra_agent_config_test.go b/pkg/telemetry/cassandra_agent/cassandra_agent_config_test.go index 63341ee9f..aaf16615d 100644 --- a/pkg/telemetry/cassandra_agent/cassandra_agent_config_test.go +++ b/pkg/telemetry/cassandra_agent/cassandra_agent_config_test.go @@ -43,70 +43,65 @@ relabels: address: 192.168.1.10 port: "50000" relabels: -- regex: org\.apache\.cassandra\.metrics\.Table.* +- regex: .+ replacement: "true" sourceLabels: - - __origname__ + - table targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table.* - replacement: "true" - sourceLabels: - - __origname__ - targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table\.live_ss_table_count +- regex: org_apache_cassandra_metrics_table_live_ss_table_count replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.Table\.LiveSSTableCount +- regex: org_apache_cassandra_metrics_table_live_disk_space_used replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table\.live_disk_space_used +- regex: org_apache_cassandra_metrics_table_memtable.* replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table\.LiveDiskSpaceUsed +- regex: org_apache_cassandra_metrics_table_all_memtables.* replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.Table\.Memtable +- regex: org_apache_cassandra_metrics_table_compaction_bytes_written replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.Table\.Compaction +- regex: org_apache_cassandra_metrics_table_pending_compactions replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table\.read +- regex: org_apache_cassandra_metrics_table_read_.* replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table\.write +- regex: org_apache_cassandra_metrics_table_write_.* replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table\.range +- regex: org_apache_cassandra_metrics_table_range.* replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table\.coordinator +- regex: org_apache_cassandra_metrics_table_coordinator_.* replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop -- regex: org\.apache\.cassandra\.metrics\.table\.dropped_mutations +- regex: org_apache_cassandra_metrics_table_dropped_mutations replacement: "false" sourceLabels: - - __origname__ + - __name__ targetLabel: should_drop - action: drop regex: "true"