Part 2: System design for PMs - scaling, load balancing, data
Module 9 · Sun 13 Sep, evening
Listen in English
Watch the reel (English)
NFRs are product decisions. A PM should define: expected scale and growth, read-heavy vs write-heavy, which data must never be lost vs where some inconsistency is OK, latency targets per journey, and which external APIs are used and what they cost.
- Vertical scaling = a bigger machine. Horizontal scaling = more machines. Start vertical; go horizontal when load justifies the extra complexity.
- A load balancer directs traffic across servers with health checks - round robin, least connections or weighted.
- Stateless servers keep user state in shared storage; sticky sessions are a workaround, not the goal. Don't keep critical state on one server.
Bandwidth (volume) and latency (delay) are different bottlenecks - fixing one doesn't fix the other. DNS turns a domain into an IP; HTTPS encrypts traffic.
Data modelling: split data into tables (class example: users, photos, likes, comments, follows) linked by primary and foreign keys. Indexing speeds up lookups in big tables (don't index everything); caching serves repeated hot reads fast. Optimise the step where users are most likely to give up.