Skip to content

Commit

Permalink
Improved logging
Browse files Browse the repository at this point in the history
  • Loading branch information
Bigomby committed Apr 13, 2016
1 parent dacc0f9 commit f803c7e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions reporthandler.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,8 @@ func (r *reportHandler) Init() {
select {
case r.unordered <- report:
break sendReportLoop
case <-time.After(100 * time.Millisecond):
logger.Warn("Error on report: Full queue")
case <-time.After(500 * time.Millisecond):
logger.Warn("Delivering report: Full queue")
}
}
} else {
Expand All @@ -111,7 +111,8 @@ func (r *reportHandler) Init() {
logger.
WithField("ID", message.report.ID).
WithField("Retry", message.report.Retries).
WithField("Reason", message.report.Status).
WithField("Status", message.report.Status).
WithField("Code", message.report.StatusCode).
Warnf("Retrying message")

<-time.After(time.Duration(r.config.backoff) * time.Second)
Expand Down

0 comments on commit f803c7e

Please sign in to comment.