When is it acceptable to denormalize?
When measurements show a read path is too slow and an index or query change cannot fix it. Denormalize deliberately, record why, and keep the normalized source of truth so the copy can be rebuilt. Doing it first, without evidence, just adds update anomalies.
Answered in
Relational Schema Design That Survives Contact With ProductionKeys, relationships, constraints and indexes: the schema decisions that decide integrity and speed, with worked SQL for one-to-many and many-to-many.
Read the full analysisOther questions this article answers
More system design & architecture questions
- How much spare capacity should a gateway keep?
- Why are bounded queues important for availability?
- Should a load balancer always move requests away from an unhealthy server?
- Can a circuit breaker prevent every cascading failure?
- Why does pagination improve API performance beyond just 'smaller responses'?
- Why is asynchronous logging faster than writing logs synchronously?
- When does caching actually help API performance, and when doesn't it?
- Why does payload compression trade CPU time for network time, and when is that worth it?
Every answer on Crashtech is written by the editor of the article it comes from — never auto-summarised. Browse all answers or the System Design & Architecture beat.