From 2bcbfe5adebdf81130c7aaab4a5d46f7579c2880 Mon Sep 17 00:00:00 2001 From: Sambhav Jain Date: Fri, 15 Nov 2024 16:22:10 +0530 Subject: [PATCH] roachtest/tests: fix quantile value in tpce Other tests emitting openmetrics emit quantiles in percentage rather than absolute value. This change intends to make tpce also emit percentage value to be more consistent will other roachtests Epic: none Release note: None --- pkg/cmd/roachtest/tests/tpce.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkg/cmd/roachtest/tests/tpce.go b/pkg/cmd/roachtest/tests/tpce.go index 9bc485bc700b..f7f9738b3f82 100644 --- a/pkg/cmd/roachtest/tests/tpce.go +++ b/pkg/cmd/roachtest/tests/tpce.go @@ -397,10 +397,10 @@ func getOpenMetrics(metrics tpceMetrics, countOfLatencies string, labelString st buffer.WriteString("# TYPE tpce_latency summary\n") buffer.WriteString("# HELP tpce_latency Latency metrics for TPC-E transactions\n") - buffer.WriteString(fmt.Sprintf("tpce_latency{%s,quantile=\"0.5\"} %s %d\n", labelString, metrics.P50Latency, now)) - buffer.WriteString(fmt.Sprintf("tpce_latency{%s,quantile=\"0.9\"} %s %d\n", labelString, metrics.P90Latency, now)) - buffer.WriteString(fmt.Sprintf("tpce_latency{%s,quantile=\"0.99\"} %s %d\n", labelString, metrics.P99Latency, now)) - buffer.WriteString(fmt.Sprintf("tpce_latency{%s,quantile=\"1.0\"} %s %d\n", labelString, metrics.PMaxLatency, now)) + buffer.WriteString(fmt.Sprintf("tpce_latency{%s,quantile=\"50.0\"} %s %d\n", labelString, metrics.P50Latency, now)) + buffer.WriteString(fmt.Sprintf("tpce_latency{%s,quantile=\"90.0\"} %s %d\n", labelString, metrics.P90Latency, now)) + buffer.WriteString(fmt.Sprintf("tpce_latency{%s,quantile=\"99.0\"} %s %d\n", labelString, metrics.P99Latency, now)) + buffer.WriteString(fmt.Sprintf("tpce_latency{%s,quantile=\"100.0\"} %s %d\n", labelString, metrics.PMaxLatency, now)) buffer.WriteString(fmt.Sprintf("tpce_latency_sum{%s} %d %d\n", labelString, 0, now)) buffer.WriteString(fmt.Sprintf("tpce_latency_count{%s} %s %d\n", labelString, countOfLatencies, now)) buffer.WriteString("# EOF")