Denormalization & Data Duplication Strategies
Model Realtime Database data for fast reads by deliberately duplicating data, choosing denormalized shapes over joins, and keeping copies consistent at write time.
NoSQL Thinking
Realtime Database has no joins. Instead of normalizing data like a relational schema, you shape data around how you read it. This often means storing the same value in more than one place.
This deliberate redundancy is called denormalization.
The Cost of Joins
In a normalized model, showing a post with its author name would require reading the post, then reading the user node separately for every post. That is many round-trips and slow lists.
All lessons in this course
- Fan-Out Data Updates
- Transactional Data Operations
- Atomic Counters & Queues
- Denormalization & Data Duplication Strategies