Skip to content

Commit

Permalink
allegro-internal/flex-roadmap#819 Migrated metrics to prometheus (lint)
Browse files Browse the repository at this point in the history
  • Loading branch information
nastassia-dailidava committed Oct 1, 2024
1 parent 4416446 commit 5edcb15
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ class SnapshotUpdater(

private fun snapshotTimer(serviceName: String) = if (properties.metrics.cacheSetSnapshot) {
meterRegistry.timer(
"simple-cache.duration.seconds", Tags.of("service", serviceName, "operation", "set-snapshot")
"simple.cache.duration.seconds", Tags.of("service", serviceName, "operation", "set-snapshot")
)
} else {
noopTimer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@ class ThreadPoolMetricTest {
val metricNames = listOf("executor.completed", "executor.active", "executor.queued", "executor.pool.size")
.map { "envoy-control.$it" }

val metricMap = listOf(
val executorNames = listOf(
"grpc-server-worker",
"grpc-worker-event-loop",
"snapshot-update",
"group-snapshot"
).associateWith { metricNames }

assertThat(metricMap.entries).allSatisfy {
assertThat(executorNames.entries).allSatisfy {
assertThat(it.value.all { metricName ->
meterRegistry.meters.any { meter ->
meter.id.name == metricName && meter.id.tags.contains(
Expand Down

0 comments on commit 5edcb15

Please sign in to comment.