Skip to content

Commit 69e2c14

Browse files
authored
fix(pool): Fix wrong tag name (#4563)
1 parent 299e9d5 commit 69e2c14

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

relay-server/src/services/stats.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ impl RelayStats {
194194

195195
metric!(
196196
gauge(RelayGauges::AsyncPoolQueueSize) = metrics.queue_size(),
197-
pool_name = async_pool.name()
197+
pool = async_pool.name()
198198
);
199199
metric!(
200200
gauge(RelayGauges::AsyncPoolUtilization) = metrics.utilization() as f64,

relay-server/src/statsd.rs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,17 @@ pub enum RelayGauges {
77
/// Tracks the number of futures waiting to be executed in the pool's queue.
88
///
99
/// Useful for understanding the backlog of work and identifying potential bottlenecks.
10+
///
11+
/// This metric is tagged with:
12+
/// - `pool`: the name of the pool.
1013
AsyncPoolQueueSize,
1114
/// Tracks the utilization of the async pool.
1215
///
13-
/// The utilization is a value between 0.0 and 1.0 which determines how busy is the pool
16+
/// The utilization is a value between 0.0 and 100.0 which determines how busy is the pool
1417
/// w.r.t. to its provisioned capacity.
18+
///
19+
/// This metric is tagged with:
20+
/// - `pool`: the name of the pool.
1521
AsyncPoolUtilization,
1622
/// The state of Relay with respect to the upstream connection.
1723
/// Possible values are `0` for normal operations and `1` for a network outage.

relay-threading/src/metrics.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,6 @@ impl AsyncPoolMetrics<'_> {
3333
.map(|m| m.active_tasks.load(Ordering::Relaxed))
3434
.sum();
3535

36-
(total_polled_futures as f32 / self.max_tasks as f32).clamp(0.0, 1.0)
36+
(total_polled_futures as f32 / self.max_tasks as f32).clamp(0.0, 1.0) * 100.0
3737
}
3838
}

0 commit comments

Comments
 (0)