Aggregate Boundaries and NoSQL Modeling

#131 - Data Essentials in Software Architecture - Pramod Sadalage

Topic 5 of 8

Published May 1, 2023 · Clip 30:30–37:32 (7:02)

Pramod explains that performance problems often come from relational thinking applied to new databases, e.g. designing document collections as if they were tables and then complaining joins are hard. He walks through aggregate boundaries with an e-commerce example: a customer aggregate containing orders with order items and payment, and when aggregates get too big (thousands of orders), splitting into customer and order aggregates with references. He recommends doing a pet project, getting training, and talking to experienced users before adopting a new database style, and warns against treating graph nodes as tables. Finally, he suggests building a performance harness with a billion documents and realistic read/write loads to test design and product choices.