Skip to content

Commit

Permalink
fix:wrong stats log (apache#907)
Browse files Browse the repository at this point in the history
  • Loading branch information
nick committed Aug 25, 2022
1 parent 2630383 commit 1a0fc5b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions consumer/statistics.go
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ func (si *statsItem) samplingInHour() {

func (si *statsItem) printAtMinutes() {
ss := computeStatsData(&si.csListMinuteLock, si.csListMinute)
rlog.Info("Stats In One Minute, SUM: %d TPS: AVGPT: %.2f", map[string]interface{}{
rlog.Info("Stats In One Minute.", map[string]interface{}{
"statsName": si.statsName,
"statsKey": si.statsKey,
"SUM": ss.sum,
Expand All @@ -433,7 +433,7 @@ func (si *statsItem) printAtMinutes() {

func (si *statsItem) printAtHour() {
ss := computeStatsData(&si.csListHourLock, si.csListHour)
rlog.Info("Stats In One Hour, SUM: %d TPS: AVGPT: %.2f", map[string]interface{}{
rlog.Info("Stats In One Hour.", map[string]interface{}{
"statsName": si.statsName,
"statsKey": si.statsKey,
"SUM": ss.sum,
Expand All @@ -444,7 +444,7 @@ func (si *statsItem) printAtHour() {

func (si *statsItem) printAtDay() {
ss := computeStatsData(&si.csListDayLock, si.csListDay)
rlog.Info("Stats In One Day, SUM: %d TPS: AVGPT: %.2f", map[string]interface{}{
rlog.Info("Stats In One Day.", map[string]interface{}{
"statsName": si.statsName,
"statsKey": si.statsKey,
"SUM": ss.sum,
Expand Down

0 comments on commit 1a0fc5b

Please sign in to comment.