Django

I started out with Django recently coming from node and I've searched for Django listening architecture and haven't found any, I would just like to know how Django listens to requests and if it's blocking, cause i read somewhere that WSGI deploys workers to interface with the python code but to this threads just wait to return responses even if it's io bound and if we have 4 workers and 4 io operations holding each, does the server reject incoming requests or store them in a queue
1 Reply
reddogg476
reddogg47611mo ago
I venture a guess it's stored in a queue. Django uses a built-in server but it's development-only; the documentation says not to ever deploy it in production environment because it's untested. https://developer.mozilla.org/en-US/docs/Learn/Server-side/Django/Deployment#choosing_a_hosting_provider When deployed to production you'll run on Apache or Nginx. Above link provides PaaS solutions: Heroku, Digital Ocean, Railway, Python Anywhere, Amazon Web Services, Azure, Google Cloud, Hetzner, and Vultr Cloud Compute. Each will have a different web server that operates with a kernel or user worker queue (probably a queue).
MDN Web Docs
Django Tutorial Part 11: Deploying Django to production - Learn web...
That's the end of this tutorial on setting up Django apps in production, and also the series of tutorials on working with Django. We hope you've found them useful. You can check out a fully worked-through version of the source code on GitHub here.
Want results from more Discord servers?
Add your server