The map
- Not started
- In progress
- Done
- Builds on
- 01How a query runsPlans, indexes and joins0/4
- 02Shaping the dataConstraints, tables and pages0/3
- 03Many writers at onceIsolation, row versions, locks0/3
- 04Running it for realConnections, replicas, partitions0/3
- 05Next: system designSame ideas, at service scale
- Cursor paginationLibrary ↗Keyset pagination is the database half of a cursor API: the cursor you hand the client is the last (created_at, id) you returned.
- Write-ahead logLibrary ↗PostgreSQL's WAL is the textbook case. The library topic shows the same idea in Kafka, etcd and other systems.
- Read replicasLibrary ↗Streaming replicas are asynchronous by default, so a read straight after a write can miss it. The library topic covers read-your-writes routing.
- Transactional outboxLibrary ↗One transaction can write the order and the event row together; a relay publishes the event afterwards, so you never commit one without the other.
- ShardingLibrary ↗Partitioning splits one table inside one server. When one server is not enough, the same choice of key decides how you shard across many.
Written for PostgreSQL 16 and 17; the links point to the version 17 manual. The examples were run on a scratch database (orders, customers and accounts tables with a few hundred thousand rows). Costs and timings in the plans will differ on your machine, but the plan shapes are what matter.
Where this path leads
- Inside the database →How databases stay durable, scale reads, and share their changes.
- Redis: fast data and its trade-offs →Why Redis is fast, which data structure fits which job, and what you give up for the speed: memory limits and eviction, persistence that can lose writes, asynchronous replicas, a cluster with hash slots, and locks with caveats.