Total qps / max qps

I want to calc (total qps / max qps)

max qps use grafana MAX

Welcome @kong62 to the Grafana forum.

Can you share your query / screenshot of Total QPS?

And within one panel, can you set up Query A as Total QPS, Query B as Max QPS (but probably modifying your Prometheus query to do the “Max” calculation), then use a transformation to calculate Total QPS / Max QPS, like this?

Or perhaps you can use two transformations: one to get the Max QPS and a second one as described above?

1 Like

total qps:
sum by(application) ({name=~“qps:http_server_requests_seconds_count:irate1m”, application=~“bbs-threadread-api”})

max qps:
max_over_time(max by(application) (sum by(application, instance) ({name=~“qps:http_server_requests_seconds_count:irate1m”, application=~“bbs-threadread-api”}))[$__range])

I want to use the line of total qps divided by a point of max qps, so that I can get another line

total qps: