mirror of https://github.com/zulip/zulip.git
eef65d7e30
Django lazy-loads much of its modules, including the application's. This defers the time to during the first request it serves. When doing rolling-restarts, this means that the worker is marked "ready" despite having multiple seconds more work to do. With small numbers of workers, this causes a significant capacity drop, since effectively more than one worker can be still reloading at a time. It also results in poor user experience for the requests which are unlucky enough to be served first. Use the technique detailed in the uwsgi documentation[^1] to fake a request during initial application load, which forces the application to be loaded. [^1]: https://uwsgi-docs.readthedocs.io/en/latest/articles/TheArtOfGracefulReloading.html#dealing-with-ultra-lazy-apps-like-django |
||
---|---|---|
.. | ||
jinja2 | ||
__init__.py | ||
backends.py | ||
computed_settings.py | ||
config.py | ||
configured_settings.py | ||
default_settings.py | ||
dev_settings.py | ||
dev_urls.py | ||
email_backends.py | ||
prod_settings.pyi | ||
prod_settings_template.py | ||
sentry.py | ||
settings.py | ||
settings_types.py | ||
template_loaders.py | ||
test_extra_settings.py | ||
test_settings.py | ||
urls.py | ||
wsgi.py |