@@ -44,13 +44,29 @@ var (
44
44
Name : "controller_runtime_reconcile_time_seconds" ,
45
45
Help : "Length of time per reconciliation per controller" ,
46
46
}, []string {"controller" })
47
+
48
+ // WorkerCount is a prometheus metric which holds the number of
49
+ // concurrent reconciles per controller
50
+ WorkerCount = prometheus .NewGaugeVec (prometheus.GaugeOpts {
51
+ Name : "controller_runtime_max_concurrent_reconciles" ,
52
+ Help : "Maximum number of concurrent reconciles per controller" ,
53
+ }, []string {"controller" })
54
+
55
+ // ActiveWorkers is a prometheus metric which holds the number
56
+ // of active workers per controller
57
+ ActiveWorkers = prometheus .NewGaugeVec (prometheus.GaugeOpts {
58
+ Name : "controller_runtime_active_workers" ,
59
+ Help : "Number of currently used workers per controller" ,
60
+ }, []string {"controller" })
47
61
)
48
62
49
63
func init () {
50
64
metrics .Registry .MustRegister (
51
65
ReconcileTotal ,
52
66
ReconcileErrors ,
53
67
ReconcileTime ,
68
+ WorkerCount ,
69
+ ActiveWorkers ,
54
70
// expose process metrics like CPU, Memory, file descriptor usage etc.
55
71
prometheus .NewProcessCollector (prometheus.ProcessCollectorOpts {}),
56
72
// expose Go runtime metrics like GC stats, memory stats etc.
0 commit comments