Module: HireFire::Backend::Resque::Redis
- Defined in:
- lib/hirefire/backend/resque/redis.rb
Instance Method Summary collapse
-
#jobs ⇒ Fixnum
Counts the amount of pending jobs in Redis.
-
#workers ⇒ Fixnum
Counts the amount of workers.
-
#working ⇒ Fixnum
Counts the amount of jobs that are being processed by workers.
Instance Method Details
#jobs ⇒ Fixnum
Counts the amount of pending jobs in Redis
Failed jobs are excluded because they are not listed as “pending” and jobs cannot be scheduled for the future in Resque
15 16 17 |
# File 'lib/hirefire/backend/resque/redis.rb', line 15 def jobs ::Resque.info[:pending].to_i end |
#workers ⇒ Fixnum
Counts the amount of workers
23 24 25 |
# File 'lib/hirefire/backend/resque/redis.rb', line 23 def workers ::Resque.info[:workers].to_i end |
#working ⇒ Fixnum
Counts the amount of jobs that are being processed by workers
31 32 33 |
# File 'lib/hirefire/backend/resque/redis.rb', line 31 def working ::Resque.info[:working].to_i end |