Skip to content

Commit

Permalink
log retry failures (#804)
Browse files Browse the repository at this point in the history
  • Loading branch information
luke-lombardi authored Dec 20, 2024
1 parent 906525a commit 09688e6
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions pkg/task/dispatch.go
Original file line number Diff line number Diff line change
Expand Up @@ -205,11 +205,7 @@ func (d *Dispatcher) RetryTask(ctx context.Context, task types.TaskInterface) er

// Hit retry limit, cancel task and resolve
if taskMessage.Retries >= taskMessage.Policy.MaxRetries {

// Don't bother logging it if the retry limit is set to 0, it's just noise
if taskMessage.Policy.MaxRetries != 0 {
log.Info().Str("task_id", taskMessage.TaskId).Str("stub_id", taskMessage.StubId).Msg("dispatcher hit retry limit, not reinserting task")
}
log.Info().Str("task_id", taskMessage.TaskId).Str("stub_id", taskMessage.StubId).Msg("dispatcher hit retry limit, not reinserting task")

err = task.Cancel(ctx, types.TaskExceededRetryLimit)
if err != nil {
Expand Down

0 comments on commit 09688e6

Please sign in to comment.