Friday, 17 August 2018

Running ApScheduler in Gunicorn Without Duplicating Per Worker

The title basically says it all. I have gunicorn running my app with 5 workers. I have a data structure that all the workers need access to that is being updated on a schedule by apscheduler.

Currently apscheduler is being run once per worker, but I just want it run once period. Is there a way to do this? I've tried using the --preload option, which let's me load the shared data structure just once, but doesn't seem to let all the workers have access to it when it updates.



from Running ApScheduler in Gunicorn Without Duplicating Per Worker

No comments:

Post a Comment