Loading...
Assumptions:
Ignore S3 object costs, that means for just post storage, that's 10^9 users x 1 post/user x 1 KB/post = 10^9 KB of growth for posts table in one day.
Annually, that's 4000 x 10^9 KB = 4 x 10^12 = 4 TB of data. Assuming growth in the other tables, that's ~100 TB growth annually.
In terms of QPS, assuming 100:1 read:write ratio, we assume each user views their feed 10x a day, so 10^9 users x 10 queries = 10^10 QPD 1 day/10^5 seconds = 10^5 QPS = 100,000. Assuming a given server can handle ~2000 QPS, then we need at least 50 servers.
High level architecture:
Regional application deployment:
Performance:
Concern:
Options for feeds reading optimization: