delayed_job vs Resque vs Sidekiq

Need advice about which tool to choose?Ask the StackShare community!

delayed_job

51
64
+ 1
6
Resque

118
125
+ 1
9
Sidekiq

1.1K
629
+ 1
408

Resque vs Sidekiq vs delayed_job: What are the differences?

Introduction

Resque, Sidekiq, and Delayed Job are popular background job management systems in Ruby on Rails. They provide a way to asynchronously process tasks and handle heavy processing operations outside of the normal request-response cycle. While they all serve the same purpose, there are key differences between them.

  1. Concurrency Model: Resque uses a multi-process approach, where each job is processed by a separate worker process. This allows for parallel processing of jobs, but it can be resource-intensive and potentially slower with a high number of jobs. Sidekiq, on the other hand, uses a multi-threaded approach, where jobs are processed within the same process using multiple worker threads. This allows for better resource utilization and faster job processing. Delayed Job also uses a multi-process approach like Resque, but it does not support multi-threading.

  2. Job Priority: Sidekiq and Delayed Job support job priority out of the box. This means that you can specify a priority for each job, and the system will prioritize the processing of higher priority jobs. Resque, however, does not have built-in support for job priority. Jobs in Resque are processed in the order they are enqueued.

  3. Redis Dependency: Resque and Sidekiq both depend on Redis for storing job queues and job-related data. Delayed Job, on the other hand, can use different backends for storing job data, including the database. This can be beneficial if your application is already using a database and you don't want to introduce an additional dependency on Redis.

  4. Retry and Error Handling: Sidekiq has built-in support for retrying failed jobs with backoff strategies, allowing for automatic job retries with increasing delays between retries. Resque and Delayed Job also support retrying failed jobs, but they require additional configurations and custom code to achieve similar behavior.

  5. Monitoring and Dashboard: Sidekiq provides a built-in monitoring dashboard that allows you to track the status of jobs, view processing statistics, and pause/resume job processing. Resque and Delayed Job do not have built-in monitoring dashboards, but you can use third-party tools or build your own monitoring system.

  6. Active Job Integration: Delayed Job seamlessly integrates with Rails' Active Job framework, allowing you to use a consistent API for working with background jobs. Resque and Sidekiq also have Active Job adapters available, but they are separate gems that need to be installed and configured separately.

In summary, Resque, Sidekiq, and Delayed Job are popular background job management systems in Ruby on Rails, but they differ in terms of concurrency model, job priority support, backend dependency, retry and error handling, monitoring capabilities, and Active Job integration.

Get Advice from developers at your company using StackShare Enterprise. Sign up for StackShare Enterprise.
Learn More
Pros of delayed_job
Pros of Resque
Pros of Sidekiq
  • 3
    Easy to get started
  • 2
    Reliable
  • 1
    Doesn't require Redis
  • 5
    Free
  • 3
    Scalable
  • 1
    Easy to use on heroku
  • 124
    Simple
  • 99
    Efficient background processing
  • 60
    Scalability
  • 37
    Better then resque
  • 26
    Great documentation
  • 15
    Admin tool
  • 14
    Great community
  • 8
    Integrates with redis automatically, with zero config
  • 7
    Stupidly simple to integrate and run on Rails/Heroku
  • 7
    Great support
  • 3
    Ruby
  • 3
    Freeium
  • 2
    Pro version
  • 1
    Dashboard w/live polling
  • 1
    Great ecosystem of addons
  • 1
    Fast

Sign up to add or upvote prosMake informed product decisions

What companies use delayed_job?
What companies use Resque?
What companies use Sidekiq?

Sign up to get full access to all the companiesMake informed product decisions

What tools integrate with delayed_job?
What tools integrate with Resque?
What tools integrate with Sidekiq?
    No integrations found
    What are some alternatives to delayed_job, Resque, and Sidekiq?
    RabbitMQ
    RabbitMQ gives your applications a common platform to send and receive messages, and your messages a safe place to live until received.
    JavaScript
    JavaScript is most known as the scripting language for Web pages, but used in many non-browser environments as well such as node.js or Apache CouchDB. It is a prototype-based, multi-paradigm scripting language that is dynamic,and supports object-oriented, imperative, and functional programming styles.
    Git
    Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency.
    GitHub
    GitHub is the best place to share code with friends, co-workers, classmates, and complete strangers. Over three million people use GitHub to build amazing things together.
    Python
    Python is a general purpose programming language created by Guido Van Rossum. Python is most praised for its elegant syntax and readable code, if you are just beginning your programming career python suits you best.
    See all alternatives