module Resqued::Config::Dsl

Defines the DSL for resqued config files.

Each subclass should override parts of the dsl that it cares about.

Public Instance Methods

after_exit(&block) click to toggle source

Public: Define a block to be run once after each worker exits.

# File lib/resqued/config/dsl.rb, line 16
def after_exit(&block)
end
after_fork(&block) click to toggle source

Public: Define a block to be run in each worker.

# File lib/resqued/config/dsl.rb, line 12
def after_fork(&block)
end
before_fork(&block) click to toggle source

Public: Define a block to be run once, before forking all the workers.

# File lib/resqued/config/dsl.rb, line 8
def before_fork(&block)
end
queue(*queues) click to toggle source

Public: Define the queues worked by members of the worker pool.

# File lib/resqued/config/dsl.rb, line 32
def queue(*queues)
end
worker(*queues) click to toggle source

Public: Define a worker that will work on a queue.

# File lib/resqued/config/dsl.rb, line 20
def worker(*queues)
end
worker_factory(&block) click to toggle source

Public: Define a factory Proc that creates Resque::Workers

# File lib/resqued/config/dsl.rb, line 28
def worker_factory(&block)
end
worker_pool(count, *queues_and_options) click to toggle source

Public: Define a pool of workers that will work ‘*’, or the queues specified by ‘queue`.

# File lib/resqued/config/dsl.rb, line 24
def worker_pool(count, *queues_and_options)
end