module Toiler::Worker::ClassMethods

Class methods for Workers

Public Instance Methods

auto_delete?() click to toggle source
# File lib/toiler/worker.rb, line 57
def auto_delete?
  class_variable_get(:@@toiler_options)[:auto_delete]
end
auto_visibility_timeout?() click to toggle source
# File lib/toiler/worker.rb, line 53
def auto_visibility_timeout?
  class_variable_get(:@@toiler_options)[:auto_visibility_timeout]
end
batch?() click to toggle source
# File lib/toiler/worker.rb, line 41
def batch?
  class_variable_get(:@@toiler_options)[:batch]
end
concurrency() click to toggle source
# File lib/toiler/worker.rb, line 45
def concurrency
  class_variable_get(:@@toiler_options)[:concurrency]
end
queue() click to toggle source
# File lib/toiler/worker.rb, line 49
def queue
  class_variable_get(:@@toiler_options)[:queue]
end
toiler_options(options = {}) click to toggle source
# File lib/toiler/worker.rb, line 35
def toiler_options(options = {})
  return class_variable_get(:@@toiler_options) if options.empty?
  Toiler.register_worker(options[:queue], self) if options[:queue]
  class_variable_get(:@@toiler_options).merge! options
end