Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose custom metrics #213

Open
joelddiaz opened this issue Mar 22, 2022 · 0 comments
Open

Expose custom metrics #213

joelddiaz opened this issue Mar 22, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@joelddiaz
Copy link
Contributor

Set up the pieces to allow reporting custom metrics. https://book.kubebuilder.io/reference/metrics.html

Start by exposing a count of the number of MondooAuditConfig resources as the first custom metric. Since this is not something that can easily be calculated during a Reconcile() loop, it may make more sense to set up a controller that just periodically runs to calculate the metrics to be reported.

https://github.com/openshift/cloud-credential-operator/blob/master/pkg/operator/metrics/ can be used as an example of setting up a controller that doesn't watch for a specific resource, but just runs at a set interval.

@imilchev imilchev added the enhancement New feature or request label May 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants