-
-
Notifications
You must be signed in to change notification settings - Fork 240
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 prometheus support #211
Comments
Yes, bunotel will support metrics. The rough estimation is next week. |
Any example usage with Treemux router is appreciated. Since metrics collection documentation is missing in the official bun website. @vmihailenco |
Well, all you should do is to configure OpenTelemetry to export metrics to Prometheus. I will write an article at blog.uptrace.dev for SEO purposes :), but for now you can try to figure that for yourself - https://github.com/open-telemetry/opentelemetry-go/blob/main/example/prometheus/main.go . The only treemux specific line is -http.HandleFunc("/", exporter.ServeHTTP)
+router.Compat().GET("/", exporter.ServeHTTP) After that you need to visualize the data somehow. With Uptrace it looks something like this The histogram accuracy (p50) is really bad, but it will be improved with exponential histograms - github.com/open-telemetry/opentelemetry-go/pull/2261. |
I come too late, do you mind i recommand otsql at here . |
@j2gg0s I've already mentioned it here and will add it to the bun readme as well. I still hope to add instructions for OpenTelemetry and Prometheus, just was busy working on OpenTelemetry mentrics documentation... |
Looking at the source code of bunotel, looks like it only support traces. Do you have any plan to support metrics exporting perhaps via opentelemetry? I want to export http metrics along with bun metrics to prometheus.
The text was updated successfully, but these errors were encountered: