18👍
✅
Django is run as a WSGI application. How that happens is determined by your WSGI server (e.g. uWSGI, Gunicorn, mod_wsgi).
Django’s request handler is thread-safe. You can configure your WSGI server to use any number of processes (sometimes called workers) and threads per process.
As you’ve mentioned, processes use more memory, but threads are affected by the GIL. A good configuration should find a balance between the number of processes and the number of threads per process.
👤knbk
Source:stackexchange.com