Job Options

The Jobly::Job class supports these class-level options:

KeyDefaultPurpose
queuedefaultset the name of the queue for this job.
retries5number of times to retry on failure.
backtrace5number of backtrace lines to show in case of failures. Can be true, false or a number of lines to save.
solofalseSpecify that this task should only be executed once. If the same job is executed while this job is running, it will be skipped. See Solo Jobs for more information.

For example:

class Deploy < Jobly::Job
  solo
  queue 'critical'
  backtrace 10
  retries 3

  def execute
    puts "Deploying"
  end
end

See Also: Solo Jobs