Rails 3 and scheduling of repetitive tasks without

2019-08-02 19:36发布

问题:

I have a app and i am currently using delayed_job. I was wondering if there are any recommended gems that do scheduling of repetitive tasks.

I want to schedule task that happen on a certain frequency to clean the database/sending emails/run other methods. I mite want to run some tasks every day or every hour.

Is there any good ones out there that are fairly easy to setup and config which do not use CRON.

回答1:

You can convert that repetitive work to rakes and call those rakes via cron. For setting cron over server, whenever is nice gem checkout here - http://railscasts.com/episodes/164-cron-in-ruby



回答2:

there are some very good gems about schedule repetitive tasks i tried delayed job it is simple and easy to use you can watch rails cast to details of using it



回答3:

You can try rufus-scheduler https://github.com/jmettraux/rufus-scheduler It is an app based scheduler (unless you use it's cron feature).