Databases · Tool
MongoDB
Flexible documents for evolving domains.
01Overview
MongoDB is a document database that stores data as flexible JSON-like documents. I use it when the domain evolves quickly and data is naturally hierarchical, especially with Node.js.
02Key concepts
What anyone working with it needs to understand
- 01
Document modeling
Embedding vs referencing, designing for access patterns.
- 02
CRUD & queries
Filters, projections and operators.
- 03
Indexes
Compound, text and TTL indexes.
- 04
Aggregation pipeline
Transforming and analyzing data in stages.
- 05
Replica sets & sharding
Availability and horizontal scale.
- 06
Transactions
Multi-document transactions and when you need them.
03In practice
Part of my NoSQL toolkit (MongoDB, Firestore, DynamoDB) for Node.js services.