class ActiveJob::QueueAdapters::SidekiqAdapter
Rails.application.config.active_job.queue_adapter = :sidekiq
To use Sidekiq set the queue_adapter config to :sidekiq
.
Read more about Sidekiq here.
processing dead simple.
require Rails but will integrate tightly with it to make background
handle many jobs at the same time in the same process. It does not
Simple, efficient background processing for Ruby. Sidekiq uses threads to
== Sidekiq adapter for Active Job
def enqueue(job) # :nodoc:
def enqueue(job) # :nodoc: # Sidekiq::Client does not support symbols as keys job.provider_job_id = Sidekiq::Client.push \ "class" => JobWrapper, "wrapped" => job.class, "queue" => job.queue_name, "args" => [ job.serialize ] end
def enqueue_at(job, timestamp) # :nodoc:
def enqueue_at(job, timestamp) # :nodoc: job.provider_job_id = Sidekiq::Client.push \ "class" => JobWrapper, "wrapped" => job.class, "queue" => job.queue_name, "args" => [ job.serialize ], "at" => timestamp end