django - Celery and Celerybeat randomly start acting funky -


I am using celery with my ginzo app and for the most part, things are going gorgeous. Here, my resume configuration is:

  CELERYBEAT_SCHEDULE = {'update-every-5-secs': {'Function': 'app1.tasks.task1', 'schedule': timedelta ( Seconds = 5), 'args': ()}}, 'archive-request-record-every-hour': {'work': 'app0.tasks.archive_requests', 'schedule': fontbab (minutes = 0, hour = '* / 1'), 'Args': (),},' Push-IOS-background-every-5-minute ': {' Work ':' app.us tasks.pus H_ios_background ',' schedule ': fontbab (min =' * / 5 '),' args': (),},}  

I have seen that every 1-2 days, Sync it will only fall completely randomly. For example, the last entry that runs every 5 minutes runs normally: 1:00, 1:05, 1:10, 1:15, etc.

What happened this morning: 7: 30, 7:35, 7:40, 7:46 , 7:50, 8:03, 8: 16, 8:32, 8:50, 9:13, 9: 21, 9:26, 9: 29, 9:32, 9:38, 9: 47, 9: 5, 10:08, 10:22 , 10:24, 10:24, 10:24, 10:24, 10:25, 10:25, 10:25, 10:25, 10:25, 10:25, 10:25, 10:25, 10 : 25, 10:25, 10:25, 10:26, 10: 26 , 10:30, 10:35, 10:40 ...

It seems that this synchronization Comes out of, once it tries to prepare for everyone, and then comes back to myself. I first thought that this is just a temporary one, but it is happening again many times. I have important mission-critical processes that need to be run on time.

Is there any way to stop it from happening? It seems that people have had so much success with Celery, so I'm really amazed.

Your settings look good.

Could it be that you are measuring the work on completion, and not at the beginning? It may be that your work takes longer or even fails, so they do not get the report.

crontab My level of experience is very low and very accurate, so I first started my logging tool.

Update

Another debugging solution is to start implementing the deadline for the task, to ensure that they are not too long locked

CELERYD_TASK_TIME_LIMIT = 300 CELERYD_TASK_SOFT_TIME_LIMIT = 260

Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -