I
I
Ilnar252018-09-14 16:24:41
Ruby on Rails
Ilnar25, 2018-09-14 16:24:41

What is better to use for background process?

The feature should accept the date and time from the params and make the message invalid when the time expires.
My idea is to start a background process that will run after the time expires and write to the message .active = false column.
Which background processes are better to use (sidekiq, delay job....). A couple of good pointers where to dig? And a couple of lines if you met with a similar task. Thank you!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
O
oh_shi, 2018-09-14
@Ilnar25

It all depends on the specific requirements.
- it may be suitable for you to perform tasks with a delay via sidekiq
https://github.com/mperham/sidekiq/wiki/Scheduled-Jobs
- it may be enough times in n to update the data in the database via cron
https://github.com/jmettraux/rufus -scheduler
https://github.com/javan/whenever
- or maybe active calls are not needed, but just enough.where('created_at < ?', 10.days.ago)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question