-
Notifications
You must be signed in to change notification settings - Fork 4
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
Add runtime metrics to prometheus #82
Comments
For this, are we converting the values in
|
yes, it is correct procedure. |
@vkuznet I tried this method using Prometheus' Go Client. I implemented this temporarily on the |
Dennis, the new code looks solid to me, and since you implemented new metrics on dedicated end-point we can proceed with their deployment and build new dashboard for them. Then, we can compare existing dashboard with new one, and, finally, merge them together. Feel free to merge and proceed with deployment on testbed. But since you put them on dedicated end-point we'll need an additional exporter to scrape them for Prometheus since k8s manifest file only allow single end-point/port to use via annotations, see https://github.com/dmwm/CMSKubernetes/blob/master/kubernetes/cmsweb/services/dbs2go-global-r.yaml#L60-L62 |
@vkuznet Would it be an issue if the metrics scraped have the same name as the original metric? Or should I modify the prefix on the new endpoint? |
Even though Promeethes us very flexible I think it would be wise to setup originally different prefix. In a long run you want to merge both metrics under single end-point and having single prefix but until everything is tested I do not want to break existing (production) dashboards, e.g. https://monit-grafana.cern.ch/d/kJOvR2h7k/dbs2go?orgId=11 |
Following approach of https://github.com/arl/statsviz/tree/1ff44fae9a7555de21fe9ad6fa09787373cf23fa we can add runtime metrics to our metrics endpoint and expose them to Prometheus. For that we should get
runtime.MemStats
object and convert it to our metrics code baseweb/metrics.go
The list of supported runtime metrics can be found here
The text was updated successfully, but these errors were encountered: