Class: SidekiqAutoscale::NilAdapter
- Inherits:
-
Object
- Object
- SidekiqAutoscale::NilAdapter
- Defined in:
- lib/sidekiq_autoscale/adapters/nil_adapter.rb
Instance Method Summary collapse
-
#initialize ⇒ NilAdapter
constructor
A new instance of NilAdapter.
- #worker_count ⇒ Object
- #worker_count=(val) ⇒ Object
Constructor Details
#initialize ⇒ NilAdapter
Returns a new instance of NilAdapter.
5 6 7 |
# File 'lib/sidekiq_autoscale/adapters/nil_adapter.rb', line 5 def initialize @sidekiq_adapter = ::SidekiqAutoscale::SidekiqInterface.new end |
Instance Method Details
#worker_count ⇒ Object
9 10 11 |
# File 'lib/sidekiq_autoscale/adapters/nil_adapter.rb', line 9 def worker_count @sidekiq_adapter.total_workers end |
#worker_count=(val) ⇒ Object
13 14 15 |
# File 'lib/sidekiq_autoscale/adapters/nil_adapter.rb', line 13 def worker_count=(val) SidekiqAutoscale.logger.debug("Attempting to autoscale sidekiq to #{val} workers") end |