Files
dennis zhuang 60899d19ee perf(servers): defer Prometheus sample value formatting to serialization (#9091)
Building a matrix response allocated one `String` per sample while the
record batches were scanned, then dropped it after the JSON body was
written. Keep the `f64` in `PromSampleValue::Number` instead and format
it with ryu while serializing, so no per-sample string is allocated.

`PromSampleValue::Text` keeps values parsed from a JSON body, so
deserializing and re-serializing a response is unchanged. Vector and
scalar results still expose `String`, since they hold a single sample.

Signed-off-by: Dennis Zhuang <xzhuang@greptime.com>
2026-09-10 04:20:57 +00:00
..
2026-06-30 07:37:31 +00:00