You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
C: unofficial, under DigitalOcean Github org, doesn't seem to have been updated since 2020
C++: unofficial, under individual GitHub account jupp0r It's not listed on the page, but there is also
rust-prometheus: owned by TiKV, not listed on the page but seems to be more used than the official rust client library
Last I checked, iirc, the official rust client library was missing some features we wanted, so we were leaning toward using the C++ library or rust-prometheus.
One of our reasons for switching was the slow speed of the histogram/ckms—our implementation is lightly modified from the C++ client libraries (and iirc, was a little faster). When this was implemented in the C++ client library, the Java implementation's linked list became a vector in C++, which causes some of the slowdown. The algorithm is also known to be faulty1.
The C++ client library isn't super well documented (for example, see the Exposer Documentation), and in the microbenchmarks that I adapted from the client library to medida, medida tended to perform better2. Other differences include Medida tracking information that Prometheus does not (e.g., one_minute_rate, five_minute_rate) and relatedly, Prometheus's /metrics endpoint only containing present (not historical values): we could work around this or have people run Grafana locally. I'll search for the results, but as I recall, the microbenchmarks in the C++ client library tended to have Medida outperforming Prometheus. There were also some considerations about integrating prometheus (and its dependencies) into core.
Given the reasons listed above, we were leaning toward exploring rust-prometheus over the C++ client library.
Since the last update, we also merged #4964, which presents an alternative to the medida histogram for measuring point loads.
Activity
marta-lokhova commentedon Jan 28, 2026
@drebelsky any learnings so far?
drebelsky commentedon Jan 28, 2026
Putting some notes on what I recall about this from last year. The client libraries with non-GC languages listed on the prometheus docs are:
jupp0rIt's not listed on the page, but there is alsoLast I checked, iirc, the official rust client library was missing some features we wanted, so we were leaning toward using the C++ library or rust-prometheus.
One of our reasons for switching was the slow speed of the histogram/
ckms—our implementation is lightly modified from the C++ client libraries (and iirc, was a little faster). When this was implemented in the C++ client library, the Java implementation's linked list became a vector in C++, which causes some of the slowdown. The algorithm is also known to be faulty1.The C++ client library isn't super well documented (for example, see the Exposer Documentation), and in the microbenchmarks that I adapted from the client library to medida, medida tended to perform better2. Other differences include Medida tracking information that Prometheus does not (e.g.,
one_minute_rate,five_minute_rate) and relatedly, Prometheus's/metricsendpoint only containing present (not historical values): we could work around this or have people run Grafana locally. I'll search for the results, but as I recall, the microbenchmarks in the C++ client library tended to have Medida outperforming Prometheus. There were also some considerations about integrating prometheus (and its dependencies) into core.Given the reasons listed above, we were leaning toward exploring rust-prometheus over the C++ client library.
Since the last update, we also merged #4964, which presents an alternative to the medida histogram for measuring point loads.
Footnotes
There's some discussion in Add rust CKMS backend #4686, this blog post, and this PR in prometheus-haskell, which corresponds to the blog post. Note also that there is an implementation of the algorithm the Haskell library uses in Apache's DataSketches. ↩
It performed better for the updating of metrics (e.g., compare counter increments).
↩drebelsky commentedon Apr 9, 2026
Closing the issue since the initial investigation is done