How scalable is Django?
My answer to How scalable is Django? on Quora
Django scales in exactly the same way as PHP or Rails or any other stateless shared-nothing web technology: you ensure that the web nodes (running your Django code) are independent from your persistence layer (database, caching, session storage etc) and scale then independently.
Since the Django web nodes have no stored state, they scale horizontally—just fire up more of then when you need them. Being able to do this is the essence of good scalability.
In my experience Java applications are more likely than Python applications to have stateful web servers which fail to scale horizontally, hence the more common need for things like load balances that support sticky sessions in the Java world.
That’s not to say you can’t have stateless Java web application servers that scale horizontally if you set out to do so—you just need to be disciplined about it.
Performance is another matter entirely: Java is generally faster than Python, and some aspects of Django (such as the template language) are actually quite slow. But performance and scalability are not the same thing.
More recent articles
- Weeknotes: Parquet in Datasette Lite, various talks, more LLM hacking - 4th June 2023
- It's infuriatingly hard to understand how closed models train on their input - 4th June 2023
- ChatGPT should include inline tips - 30th May 2023
- Lawyer cites fake cases invented by ChatGPT, judge is not amused - 27th May 2023
- llm, ttok and strip-tags - CLI tools for working with ChatGPT and other LLMs - 18th May 2023
- Delimiters won't save you from prompt injection - 11th May 2023
- Weeknotes: sqlite-utils 3.31, download-esm, Python in a sandbox - 10th May 2023
- Leaked Google document: "We Have No Moat, And Neither Does OpenAI" - 4th May 2023
- Midjourney 5.1 - 4th May 2023
- Prompt injection explained, with video, slides, and a transcript - 2nd May 2023