109 points · by pajju · 14y ago · 39 comments
* We use Flask and nginx in various areas now (the main app is still Django). Our realtime app, for example, is powered off of uwsgi and Flask.
* There are nearly 1b monthly uniques across the network serviced by the platform.
* ~300 servers
* Still Postgres (with Slony, multiple clusters), Redis, Memcache, and some Cassandra for newer things (not comments).
Also mostly confident we're still the "largest Django app" in terms of traffic.
Care to update on the other stats like requests at peak? Also, I wonder - if you're at 1b uniques is there anywhere to grow from here other then more engagement?
Oh, also: Would you say the 1% contribute, 9% curate, 90% consume heuristic holds true in your experience at this scale or is it even more skewed?
Also why the decision to use an ORM? To manage the partitions?
That said, we do manage our partitions (currently) using an ORM layer (at the application level). We do want to break this out into a proxy middleware at some point though.
Sharing images is a fairly simple task.
I don't really understand why Disqus and Reddit for that matter don't just switch to redis. There has got to be a good reason because I can't think of one. Sounds like you could run the whole thing from just one box and only have slaves for redundancy.
Why isn't vertical scaling more in vogue?
I'd love for you to elaborate. As far as I can tell they are not using PostgreSQL as a relational database, but rather, as a column store. So why not use Cassandra or even Redis (if the amount of data can totally fit into RAM easily, maybe it can't)?
In fact I think Reddit moved to Cassandra... anyway, I am not an expert, I'm asking.
http://www.slideshare.net/zeeg/djangocon-2010-scaling-disqus...
* Version upgrades (streaming replication requires the same PG version between master/slave, slony does not)
* Logical replication gives us finer-grained control over how data is replicated across the cluster
* Ability to create additional indexes on slaves
slony isn't perfect and it has caused us some headaches, but its flexibility makes it our go-to replication tool for postgres.
Hammer and screws.
* what would you see as the right they of app for Django, if not this? Obviously Django is handling it, so what's the issue?
* what is the right tool to build a distributed comment system?
What is django? A framework with strong routing, OR-mapping, templates and admin modules.
You need none to build it. Your main concern shouldn't be a coding framework, but load balancing, caching, failover control, more sysadmin stuff than code.
Any language could do. Framework? not needed.
Now, for the backend system to control that monster, then yes, you may use django.
So, use django for complex apps that need routing, data management and UI presentation, plus a powerful admin module.
* I am a python/django developer.
This is how Disqus works. Something still has to power the API that serves the data for it and we happen to like Django a lot so that's what we use. There are also a lot of parts of Disqus that are not the embed (moderation panel, account management, etc.)