Skip to content

Commit

Permalink
logging: Ignore debug logs of timer ticks for internal telemetry heal…
Browse files Browse the repository at this point in the history
…th checks

Fixes: #556
  • Loading branch information
Justin Reagor committed May 2, 2018
1 parent 1aa69d8 commit 408dbc9
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion events/timer.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,12 @@ func NewEventTimer(
return
case <-ticker.C:
event := Event{Code: TimerExpired, Source: name}
log.Debugf("timer: %v", event)
// do not log the telemetry health check timer ticks since this
// log statement is called once for every internal heartbeat
// check, which is a bit excessive under DEBUG logging [GH-556]
if event.Source != "containerpilot.heartbeat" {
log.Debugf("timer: %v", event)
}
rx <- event
}
}
Expand Down

0 comments on commit 408dbc9

Please sign in to comment.