123456789_123456789_123456789_123456789_123456789_

Class: ActiveJob::QueueAdapters::SuckerPunchAdapter

Relationships & Source Files
Super Chains via Extension / Inclusion / Inheritance
Class Chain:
Instance Chain:
Inherits: ActiveJob::QueueAdapters::AbstractAdapter
Defined in: activejob/lib/active_job/queue_adapters/sucker_punch_adapter.rb

Overview

Sucker Punch adapter for Active Job

Sucker Punch is a single-process Ruby asynchronous processing library. This reduces the cost of hosting on a service like Heroku along with the memory footprint of having to maintain additional jobs if hosting on a dedicated server. All queues can run within a single application (e.g. Rails, Sinatra, etc.) process.

Read more about Sucker Punch here.

To use Sucker Punch set the queue_adapter config to :sucker_punch.

Rails.application.config.active_job.queue_adapter = :sucker_punch

Instance Method Summary

Instance Method Details

#check_adapter

[ GitHub ]

  
# File 'activejob/lib/active_job/queue_adapters/sucker_punch_adapter.rb', line 21

def check_adapter
  ActiveJob.deprecator.warn <<~MSG.squish
    The `sucker_punch` adapter is deprecated and will be removed in Rails 8.1.
    Please use the `async` adapter instead.
  MSG
end