Skip to content

Commit

Permalink
allegro-internal/flex-roadmap#819 removed snapshot updater timer
Browse files Browse the repository at this point in the history
  • Loading branch information
nastassia-dailidava committed Oct 18, 2024
1 parent 8979a5c commit 115f415
Showing 1 changed file with 0 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import io.envoyproxy.controlplane.cache.SnapshotCache
import io.envoyproxy.controlplane.cache.v3.Snapshot
import io.micrometer.core.instrument.MeterRegistry
import io.micrometer.core.instrument.Tags
import io.micrometer.core.instrument.Timer
import pl.allegro.tech.servicemesh.envoycontrol.groups.CommunicationMode.ADS
import pl.allegro.tech.servicemesh.envoycontrol.groups.CommunicationMode.XDS
import pl.allegro.tech.servicemesh.envoycontrol.groups.Group
Expand Down Expand Up @@ -198,13 +197,10 @@ class SnapshotUpdater(
}
}

private val updateSnapshotForGroupsTimer = meterRegistry.timer("snapshot.update.duration.seconds")

private fun updateSnapshotForGroups(
groups: Collection<Group>,
result: UpdateResult
): Mono<UpdateResult> {
val sample = Timer.start()
versions.retainGroups(cache.groups())
val results = Flux.fromIterable(groups)
.doOnNextScheduledOn(groupSnapshotScheduler) { group ->
Expand All @@ -222,7 +218,6 @@ class SnapshotUpdater(
}
}
return results.then(Mono.fromCallable {
sample.stop(updateSnapshotForGroupsTimer)
result
})
}
Expand Down

0 comments on commit 115f415

Please sign in to comment.