Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question about calling runcrons while a previous job is happening #67

Closed
DanielStevenLewis opened this issue Sep 10, 2015 · 2 comments
Closed

Comments

@DanielStevenLewis
Copy link

If manage.py runcrons is called while a django-cron do function hasn't yet finished running, and that django-cron do function isn't scheduled to run again yet at that point in time, will there be a problem? I'm asking because I'm wondering whether some issues I'm experiencing might be due to having scheduled the (crontab -e) cron job to run too frequently.

@craiglabenz
Copy link

django-cron uses your configured cache backend to store which jobs are currently in-flight. Unless you designate a job as being able to run in parallel, django-cron will not re-invoke it while an earlier version is still working.

@chachra
Copy link
Member

chachra commented Dec 9, 2015

@craiglabenz thanks for answering. @DanielStevenLewis as Craig mentioned its all configurable. If you allow parallel runs and crontab executes these quicker than necessary (say via bash file that goes in a loop) or every second and the cron python execution is slow because of whatever reason, then you could easily end up with a ton of processes which is a potential problem. Hence by default parallel runs for the same cron (code) don't work.

@chachra chachra closed this as completed Dec 9, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants