From 61a5c13004107fe5f0fa4a36b00d4149a10d20cb Mon Sep 17 00:00:00 2001 From: Kerkesni Date: Thu, 16 Jan 2025 13:17:15 +0100 Subject: [PATCH] rename queue populator metrics Some queue populator metrics are shared between all extensions and not specific to replication. Issue: BB-527 --- lib/queuePopulator/QueuePopulator.js | 8 ++++---- monitoring/replication/dashboard.json | 2 +- monitoring/replication/dashboard.py | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/queuePopulator/QueuePopulator.js b/lib/queuePopulator/QueuePopulator.js index 191fbb27f..55b8fa34b 100644 --- a/lib/queuePopulator/QueuePopulator.js +++ b/lib/queuePopulator/QueuePopulator.js @@ -36,25 +36,25 @@ const metricLabels = ['origin', 'logName', 'logId']; */ const logReadOffsetMetric = ZenkoMetrics.createGauge({ - name: 's3_replication_read_offset', + name: 's3_backbeat_populator_read_offset', help: 'Current read offset of metadata journal', labelNames: metricLabels, }); const logSizeMetric = ZenkoMetrics.createGauge({ - name: 's3_replication_log_size', + name: 's3_backbeat_populator_log_size', help: 'Current size of metadata journal', labelNames: metricLabels, }); const logTimestamp = ZenkoMetrics.createGauge({ - name: 's3_replication_log_timestamp', + name: 's3_backbeat_populator_log_timestamp', help: 'Last timestamp read from the metadata journal', labelNames: metricLabels, }); const messageMetrics = ZenkoMetrics.createCounter({ - name: 's3_replication_populator_messages_total', + name: 's3_backbeat_populator_messages_total', help: 'Total number of Kafka messages produced by the queue populator', labelNames: [...metricLabels, 'publishStatus'], }); diff --git a/monitoring/replication/dashboard.json b/monitoring/replication/dashboard.json index 9a1ecc273..5d429542f 100644 --- a/monitoring/replication/dashboard.json +++ b/monitoring/replication/dashboard.json @@ -1972,7 +1972,7 @@ "targets": [ { "datasource": null, - "expr": "clamp_min(\n max(mongodb_mongod_replset_oplog_head_timestamp{\n namespace=\"${namespace}\", job=\"${job_mongod}\"})\n -\n min(s3_replication_log_timestamp{namespace=\"${namespace}\",\n job=\"${job_queue_populator}\"}),\n0)", + "expr": "clamp_min(\n max(mongodb_mongod_replset_oplog_head_timestamp{\n namespace=\"${namespace}\", job=\"${job_mongod}\"})\n -\n min(s3_backbeat_populator_log_timestamp{namespace=\"${namespace}\",\n job=\"${job_queue_populator}\"}),\n0)", "format": "time_series", "hide": false, "instant": false, diff --git a/monitoring/replication/dashboard.py b/monitoring/replication/dashboard.py index c92244e00..462b91182 100644 --- a/monitoring/replication/dashboard.py +++ b/monitoring/replication/dashboard.py @@ -462,7 +462,7 @@ def up(component: str, expr: str = None, title: str = None, **kwargs): ' max(mongodb_mongod_replset_oplog_head_timestamp{', ' namespace="${namespace}", job="${job_mongod}"})', ' -', - ' min(s3_replication_log_timestamp{namespace="${namespace}",', + ' min(s3_backbeat_populator_log_timestamp{namespace="${namespace}",', ' job="${job_queue_populator}"}),', '0)', ]),