Skip to content

Commit

Permalink
better metric name
Browse files Browse the repository at this point in the history
  • Loading branch information
Dav1dde committed Nov 24, 2023
1 parent 934c434 commit 64aefb3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions relay-metrics/src/meta/aggregator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ use crate::{statsd::MetricCounters, MetricResourceIdentifier};
/// of this happening is small enough to just add it to the storage worst case.
#[derive(Debug)]
pub struct MetaAggregator {
///
/// All tracked code locations.
locations: hashbrown::HashMap<Scope, HashSet<Location>>,

/// Maximum tracked locations.
Expand Down Expand Up @@ -64,7 +64,7 @@ impl MetaAggregator {
return None;
}

relay_statsd::metric!(counter(MetricCounters::MetaLocationUpdate) += 1);
relay_statsd::metric!(counter(MetricCounters::MetaAggregatorUpdate) += 1);
Some(MetricMeta {
timestamp: meta.timestamp,
mapping: send_upstream,
Expand Down
2 changes: 1 addition & 1 deletion relay-metrics/src/meta/protocol.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ pub struct Location {
pub function: Option<String>,
/// The line number.
#[serde(skip_serializing_if = "Option::is_none")]
pub lineno: Option<u64>, // TODO nachschauen
pub lineno: Option<u64>,
}

/// A Unix timestamp that is truncated to the start of the day.
Expand Down
4 changes: 2 additions & 2 deletions relay-metrics/src/statsd.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ pub enum MetricCounters {
BucketsDropped,
/// Incremented every time the meta aggregator emitted an update that needs to be stored or
/// sent upstream.
MetaLocationUpdate,
MetaAggregatorUpdate,
/// Incremented every time a redis key is updated to store or update metadata.
MetaRedisUpdate,
}
Expand All @@ -61,7 +61,7 @@ impl CounterMetric for MetricCounters {
Self::MergeHit => "metrics.buckets.merge.hit",
Self::MergeMiss => "metrics.buckets.merge.miss",
Self::BucketsDropped => "metrics.buckets.dropped",
Self::MetaLocationUpdate => "metrics.meta.agg.miss",
Self::MetaAggregatorUpdate => "metrics.meta.agg.update",
Self::MetaRedisUpdate => "metrics.meta.redis.update",
}
}
Expand Down

0 comments on commit 64aefb3

Please sign in to comment.