meetings / gearsloth

Gearman job persistence and delayed execution system
MIT License
2 stars 0 forks source link

Task executed multiple times if no worker available instantly #59

Closed kenkku closed 10 years ago

kenkku commented 10 years ago

When the retry controller executes a task, it tries to send the task again after a certain timeout (5 seconds by default). If there are no workers available to run the task, the Gearman server will queue all the sent tasks, resulting in a flood of tasks to the first worker to come online.

Steps to reproduce:

  1. send a task (using retry controller) with func_name that has no workers available
  2. wait for the retry controller to repeat the task a few times (since it timed out)
  3. bring online a worker, observe it receiving the same task several times from Gearman's queue
amv commented 10 years ago

This bug is fixed by changing how the retry controller works. #62 contains these changes and new tests for the retry controller. This can be closed then #62 is merged.

tstarck commented 10 years ago

Closing since #62 has been merged. Reopen if necessary.