add qps statistic; avoid a possible dead lock