Asked about Back-of-envelope numbers
Estimate the storage needed for a year of chat history for 10 million daily users.
An answer that works
Assume about 20 messages per user per day at roughly 1 KB each including metadata: 200 million messages a day, about 73 billion a year, around 73 TB, roughly 220 TB with three replicas before indexes. Then say which assumption the answer is most sensitive to.
Reading an answer is not being able to give one. The section that teaches this is Back-of-envelope numbers, 3 hours of Distributed systems.
Learn this properlyAlso asked about Distributed systems
How would you scale a read-heavy service?What is a cache stampede and how do you prevent it?Why do queue handlers need to be idempotent?Explain eventual consistency.How would you design a rate limiter?Fan-out on write or fan-out on read for a news feed?Your service calls eight internal dependencies. Each promises 99.9 per cent. What can you promise?How do you make a payment operation safe to retry?