What are the benefits of celerybeat over cron?

I see that many people prefer celery to work cron for periodic tasks. I see the documentation for celerybeat and I can see information on how to use it, but not why (or when) I should prefer it over cronjobs.

http://docs.celeryproject.org/en/latest/userguide/periodic-tasks.html#introduction

+4
source share
1 answer

I used both options and came to the conclusion that it is better to control the control than cron.

You can connect it so that your control is through django admin instead of sshing in and changing crontab. In addition, there is implicit portability when using a runout - this means that you can move it from machine to machine using the configuration instead of logging in.

Of course, there are drawbacks, but they are few. We used pid files to control the singleton aspect of the job, but now we use a common database semaphore table (other people used memcache, but I just don’t feel comfortable with that).

+3
source

Source: https://habr.com/ru/post/1484992/


All Articles