Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
controller-runtime also calls `metrics.Register()` during init and this function can be called only once. To ensure that the k8s client metrics get updated, the global variables need to be set again by the operator. https://github.com/kubernetes-sigs/controller-runtime/blob/67b27f27e514bd9ac4cf9a2d84dec089ece95bf7/pkg/metrics/client_go_adapter.go#L42-L55 https://github.com/kubernetes/client-go/blob/aa7909e7d7c0661792ba21b9e882f3cd6ad0ce53/tools/metrics/metrics.go#L129-L170 Signed-off-by: Simon Pasquier <spasquie@redhat.com>
- Loading branch information