Becuase executionMinTime is initialized as zero (long default):
— org.hibernate.stat.QueryStatistics.java ----
private long executionMinTime;
and, the logic for assignment statement is:
void executed(long rows, long time) {
if (time < executionMinTime) executionMinTime = time;
...
I think the initial value for executionMinTime should be:
private long executionMinTime = Long.MAX_VALUE;
Currently, the avg, min, max values for first run of every query are:
avg=123, min=0, max=123
at this time, you known, the min value can't be large than 0 for ever.