- Number of seconds:
- 1 day: 100k
- 1 month: 2.5M
- Number of users:
- USA: 300M
- Social networks (i.e. daily active users):
- Facebook: 2B
- YouTube, WhatsApp: 1B. (YouTube hasn’t published its DAU but it’s definitely going to be more than Instagram’s, so 1B should be fine.)
- Instagram: 500M
- Snapchat, Twitter: 200M
- Reddit: 50M
- Proportion of users who create vs consume: 1%
- 80-20 rule: 20% things get 80% traffic. So, assume cache rate of 20%.
- Machine:
- Number of connections an average modern server can handle: 50k
- Latency (see more here, ignore other Google search results as the numbers there are outdated):
- Read 1MB from:
- Memory: 3 us
- SSD: 50 us
- Disk: 825 us
- Network round trip:
- Same data center: 0.5 ms
- Halfway across the earth: 150 ms
- ID:
- Assume number of bytes for a string = 2 * length.
- Assume you use [a-z, A-Z, 0-9] to generate your IDs. Then 62^8 is a huge number that should suffice for most use cases.
- UUIDs are 16 bytes.
- Bytes:
- KB =1e3 bytes.
- MB = 1e6 bytes.
- GB = 1e9 bytes.
- TB = 1e12 bytes.
- PB = 1e15 bytes.