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 concurrency based metrics #819

Open
dhumphries-sainsburys opened this issue Mar 28, 2023 · 2 comments
Open

Expose concurrency based metrics #819

dhumphries-sainsburys opened this issue Mar 28, 2023 · 2 comments

Comments

@dhumphries-sainsburys
Copy link

In a separate issue we are looking at issues with concurrency but it is hard to get a true grasp of any problem real or perceived without concrete metrics. We have some for things interacting with flux but the actual inner workings of things such as the kustomize-controller are sadly hidden from us so we are left guessing at what is happening with. Is it possible to expose some useful concurrency metrics to prometheus such as:

queue depth
thread timings
active thread counts

Whilst the above are things that we think could be useful for our current state more metrics wouldn't be a bad thing (even better if we could also turn off any that aren't needed)

@stefanprodan
Copy link
Member

We expose all the Go runtime metrics, you can find there metrics about go routines (there are no threads in Go), heap size, etc.

@dhumphries-sainsburys
Copy link
Author

Having had a look i can see the go metrics as suggested and turns out there is metrics for threads in go called go_threads from prometheus which aligns with the concurrency option (18 + concurrency value) although it also seems that the count isn't so useful as it just puts them into a wait when doing nothing so you can't see how busy it is from the metric.

The more valuable metrics we need which i don't see exposed anywhere is something like a queue depth as we know we are pushing kustomize with a lot of work when our webhooks fire but we have no idea how far through the queue it is at any time we just have to watch the status field of the objects and as they only update when actively being reconciled the exposed metric of gotk_reconcile_condition isn't all that useful for knowing the current state

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants