In Ruby on Rails (ROR), an external library backend must be integrated in order to execute a job.
ROR has multiple built-in queuing adapters for the backend, such as Resque, Sidekiq, Delayed Job, etc.
We can easily set the backend of the application, as demonstrated below. After this, all jobs that require the backend will interact with the one specified here.
# config/app.rb module Name class App < Rails::App config.active_job.queue_adapter = :sidekiq end end
We can also set the backend as per each job that overrides the backend of the entire application set for that particular job. We can perform this operation as follows:
class GuestsCleanupJob < ApplicationJob self.queue_adapter = :resque # ... end
RELATED TAGS
CONTRIBUTOR
View all Courses