Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is difference between perform_in and perform_async in sidekiq?

I want to update old sidekiq jobs with new time interval. How I can do this ? Is it possible through perform_in option. In addition I want to know clear difference between perform_in and perform_async.

like image 291
Prakash Laxkar Avatar asked Apr 20 '16 03:04

Prakash Laxkar


People also ask

What are Sidekiq workers?

Workarea applications use Sidekiq as a job queuing backend to perform units of work asynchronously in the background. These jobs, which include search indexing, cache busting, and cleanup of expired data, are defined as workers .

Is Sidekiq multithreaded?

At the same time, Sidekiq uses multithreading so it is much more memory-efficient than Rescue.

Does Sidekiq require Redis?

Sidekiq uses Redis as an in-memory data structure store and is written in Ruby.

How does Redis work with Sidekiq?

Sidekiq is one of the more widely used background job frameworks that you can implement in a Rails application. It is backed by Redis, an in-memory key-value store known for its flexibility and performance. Sidekiq uses Redis as a job management store to process thousands of jobs per second.


1 Answers

You have to pass perform_in a time. perform_async gets pushed to the queue right away. Other than that they're the same. You'd call perform_in(10.minutes)

like image 77
toddmetheny Avatar answered Sep 20 '22 13:09

toddmetheny