]> git.feebdaed.xyz Git - 0xmirror/cilium.git/commit
policy: add selector cache metrics
authorOdin Ugedal <ougedal@palantir.com>
Wed, 19 Nov 2025 11:45:15 +0000 (12:45 +0100)
committerAndré Martins <aanm@users.noreply.github.com>
Thu, 18 Dec 2025 04:14:42 +0000 (04:14 +0000)
commitc83ca7065870381b1dccde4e753bbb9ad17cf9d0
tree90f82c1d7c96c5f6f4ae0cbaf5d65cea3b9fa269
parent9145cd874906255b3e63143d317214245ce6cf83
policy: add selector cache metrics

This adds a new set of metrics for the selector cache. Both in terms of cardinality,
but also around the performance of various operations.

Contention in the selector cache can easily make regenerations slower,
and potentially grind the whole agent to a halt in special cases. This
allows us to use these metrics to better observe the performance of
these operations.

Signed-off-by: Odin Ugedal <odin@ugedal.com>
Signed-off-by: Odin Ugedal <ougedal@palantir.com>
pkg/policy/metrics.go
pkg/policy/selectorcache.go
pkg/policy/types/metrics.go