meskyanichi/hirefire-resource — pull request #5 by eckardt (2013-03-28 14:48:42+00:00)
Title: Count jobs in progress as well

With the current way of counting the number of jobs per queue right now there is an issue for long-running jobs:

The hirefire service will scale down the respective worker dyno while the job is still running causing the long running job to be killed before it is finished.

This pull request changes the resque macro to take jobs in progress into account when calculating the number of jobs per queue and therefore solves the problem.