Skip to content

Commit

Permalink
Merge pull request #8 from uafrica/delay-before-requeue
Browse files Browse the repository at this point in the history
Add 100ms delay before requeue
  • Loading branch information
Johan Meiring committed Dec 5, 2016
2 parents e27019f + ead972f commit d580eaa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/DelayedJob/JobManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,9 @@ public function startConsuming()

$this->djLog(__('Will retry job {0}', $job->getId()));

// Sleep 100ms before requeuing the job... sometimes RabbitMQ is just too fast.
usleep(100 * 1000);

$this->requeueJob($job);

return;
Expand Down

0 comments on commit d580eaa

Please sign in to comment.