Create a separate registry for work-queue metrics #2670
Labels
kind/feature
Categorizes issue or PR as related to a new feature.
kind/support
Categorizes issue or PR as a support question.
lifecycle/stale
Denotes an issue or PR has remained open with no activity and has become stale.
Hi all!
We are using custom controllers to manage our custom resources, and wish to export the workqueue metrics to Prometheus.
This is done by using the
workqueue.SetProvider()
provided bykubernetes.io/client-go
.When we try to register our metrics using this function in our
init()
, this doesn't take effect, as theinit()
function being used in themetrics
package of this repo seems to making the call toSetProvider()
first.We can make use of this registry that you provide. It however comes with a whole lot of other metrics which we do not wish to export, such as - leader election, latency, request size, response size and other client metrics. And since they're
internal
we aren't able to unregister them.Wonder if we can either:
init()
function altogether in themetrics.go
file. Instead provide those functionalities as a separate function, so that we users can call it in ourinit()
. This way, if we choose to, we can create our own metrics and callSetProvider()
ourselves.I'm up for working on this issue.
The text was updated successfully, but these errors were encountered: