pgbadger
pgbadger copied to clipboard
Avg duration 0ms
In Most Frequent Queries, if Min duration is eq to 0, then number in Avg is zero too (and it seems it's not correct):
@rus-ik Since The avg duration is expressed as an rounded number of milliseconds. Let's take the last row, I think the average should be the following: (15000 + 696) / 300281 = 0.0522
which is rounded to zero. The same applies to the other rows.
It sounds correct, thanks.. but I'd rather suggest to use a percentile (or a quantile) in this case, since the avg (when it's rounded to zero) becomes useless and shows nothing....
jfyi https://www.dynatrace.com/news/blog/why-averages-suck-and-percentiles-are-great/
I agree that having percentile reported would be useful, but may increase the time to generate reports. Must be evaluated.