Skip to content

Commit

Permalink
Fixed error check.
Browse files Browse the repository at this point in the history
  • Loading branch information
Antoon Prins committed Aug 25, 2020
1 parent d2fba93 commit 9252486
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/metrics/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,9 @@ func init() {
// periodic record metrics data call; every 5 seconds
go func() {
for {
m.recordMetrics()
if err := m.recordMetrics(); err != nil {
log.Error().Err(err).Msg("Metrics recording failed.")
}
<-time.After(time.Millisecond * time.Duration(5000))
}
}()
Expand Down

0 comments on commit 9252486

Please sign in to comment.