From 44fd3a88705f0b3bce0b4f4c4e56d5eb3bfcf18e Mon Sep 17 00:00:00 2001 From: Matilda Clerke Date: Thu, 17 Oct 2024 10:17:21 +1100 Subject: [PATCH 1/3] 7311: Use taskName instead of className for labelNames Signed-off-by: Matilda Clerke --- .../eth/manager/peertask/PeerTaskExecutor.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java b/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java index 2653fd6f35..e769fcc8e4 100644 --- a/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java +++ b/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java @@ -58,37 +58,37 @@ public class PeerTaskExecutor { BesuMetricCategory.PEERS, "PeerTaskExecutor:RequestTime", "Time taken to send a request and receive a response", - "className"); + "taskName"); partialSuccessCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, "PeerTaskExecutor:PartialSuccessCounter", "Counter of the number of partial success occurred", - "className"); + "taskName"); timeoutCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, "PeerTaskExecutor:TimeoutCounter", "Counter of the number of timeouts occurred", - "className"); + "taskName"); invalidResponseCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, "PeerTaskExecutor:InvalidResponseCounter", "Counter of the number of invalid responses received", - "className"); + "taskName"); internalExceptionCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, "PeerTaskExecutor:InternalExceptionCounter", "Counter of the number of internal exceptions occurred", - "className"); + "taskName"); inflightRequestGauge = metricsSystem.createLabelledGauge( BesuMetricCategory.PEERS, "PeerTaskExecutor:InflightRequestGauge", "Gauge of the number of inflight requests", - "className"); + "taskName"); inflightRequestCountByClassName = new ConcurrentHashMap<>(); } From ac1c4ed9d475f08c885cc71db42443c6fa52c540 Mon Sep 17 00:00:00 2001 From: Matilda Clerke Date: Thu, 17 Oct 2024 10:19:47 +1100 Subject: [PATCH 2/3] 7311: Use snake_case for metric names Signed-off-by: Matilda Clerke --- .../eth/manager/peertask/PeerTaskExecutor.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java b/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java index e769fcc8e4..fcd5328157 100644 --- a/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java +++ b/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java @@ -56,37 +56,37 @@ public class PeerTaskExecutor { requestTimer = metricsSystem.createLabelledTimer( BesuMetricCategory.PEERS, - "PeerTaskExecutor:RequestTime", + "request_time", "Time taken to send a request and receive a response", "taskName"); partialSuccessCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, - "PeerTaskExecutor:PartialSuccessCounter", + "partial_success_counter", "Counter of the number of partial success occurred", "taskName"); timeoutCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, - "PeerTaskExecutor:TimeoutCounter", + "timeout_counter", "Counter of the number of timeouts occurred", "taskName"); invalidResponseCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, - "PeerTaskExecutor:InvalidResponseCounter", + "invalid_response_counter", "Counter of the number of invalid responses received", "taskName"); internalExceptionCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, - "PeerTaskExecutor:InternalExceptionCounter", + "internal_exception_counter", "Counter of the number of internal exceptions occurred", "taskName"); inflightRequestGauge = metricsSystem.createLabelledGauge( BesuMetricCategory.PEERS, - "PeerTaskExecutor:InflightRequestGauge", + "inflight_request_gauge", "Gauge of the number of inflight requests", "taskName"); inflightRequestCountByClassName = new ConcurrentHashMap<>(); From 750353585f8368312d4b3743c3001f8027557c04 Mon Sep 17 00:00:00 2001 From: Matilda Clerke Date: Thu, 17 Oct 2024 10:21:16 +1100 Subject: [PATCH 3/3] 7311: Use _total metric name suffix Signed-off-by: Matilda Clerke --- .../ethereum/eth/manager/peertask/PeerTaskExecutor.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java b/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java index fcd5328157..0671791436 100644 --- a/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java +++ b/ethereum/eth/src/main/java/org/hyperledger/besu/ethereum/eth/manager/peertask/PeerTaskExecutor.java @@ -62,25 +62,25 @@ public class PeerTaskExecutor { partialSuccessCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, - "partial_success_counter", + "partial_success_total", "Counter of the number of partial success occurred", "taskName"); timeoutCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, - "timeout_counter", + "timeout_total", "Counter of the number of timeouts occurred", "taskName"); invalidResponseCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, - "invalid_response_counter", + "invalid_response_total", "Counter of the number of invalid responses received", "taskName"); internalExceptionCounter = metricsSystem.createLabelledCounter( BesuMetricCategory.PEERS, - "internal_exception_counter", + "internal_exception_total", "Counter of the number of internal exceptions occurred", "taskName"); inflightRequestGauge =