mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-02 01:39:02 +00:00
Merge pull request #116033 from chengjoey/fix/apiserver-metrics
fix apiserver metrics `RecordsWatchCacheCapacityChange` use watchCacheCapacity as increase total
This commit is contained in:
@@ -179,7 +179,7 @@ func RecordListCacheMetrics(resourcePrefix, indexName string, numFetched, numRet
|
|||||||
func RecordsWatchCacheCapacityChange(objType string, old, new int) {
|
func RecordsWatchCacheCapacityChange(objType string, old, new int) {
|
||||||
WatchCacheCapacity.WithLabelValues(objType).Set(float64(new))
|
WatchCacheCapacity.WithLabelValues(objType).Set(float64(new))
|
||||||
if old < new {
|
if old < new {
|
||||||
WatchCacheCapacity.WithLabelValues(objType).Inc()
|
watchCacheCapacityIncreaseTotal.WithLabelValues(objType).Inc()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
watchCacheCapacityDecreaseTotal.WithLabelValues(objType).Inc()
|
watchCacheCapacityDecreaseTotal.WithLabelValues(objType).Inc()
|
||||||
|
Reference in New Issue
Block a user