- How MVCC Works and Why Databases Use It
๐ 12 min read
Multi-version concurrency control lets readers and writers proceed without blocking each other. A breakdown of the core mechanics, and how PostgreSQL, CockroachDB, and MySQL InnoDB implement them.
Read more โ - Write-Ahead Logging and Database Durability
๐ 10 min read
Write-ahead logging is the mechanism behind crash safety in almost every serious storage system. This post explains how it works from first principles, and how PostgreSQL, SQLite, RocksDB, and etcd each implement the same core idea.
Read more โ - Pagination: cursor or offset?
๐ 6 min read
When to use cursor-based vs offset-based pagination.
Read more โ - The "One-Way Street" Problem: Why We Clone Request Bodies in Go
๐ 7 min read
If you're coming from languages like Python or Java, Go's handling of HTTP request bodies might feel like a trap. We try to read a request body twice (e.g. once for logging and once for processing) and the second time, it's mysteriously empty.
Read more โ - Adding Full-Stack Observability to a Go Worker Pool
๐ 20 min read
How to add metrics, logs, and traces to a Go worker pool using Prometheus, Loki, Tempo, and Grafana, with every import and config line explained.
Read more โ - What Happens When You Write a Row to PostgreSQL
๐ 23 min read
A deep dive into the journey of a single INSERT statement through PostgreSQL: from query parsing and planning, through the WAL, buffer pool, and heap file, to the moment your data is truly durable.
Read more โ - Building a Worker Pool in Go
๐ 12 min read
When you have a list of tasks to run concurrently, the naive approach is to spin up one goroutine per task. That works until it doesn't. A worker pool gives you bounded concurrency, backpressure, and clean shutdown without much added complexity.
Read more โ - Runtime Choices in Distributed Systems
๐ 10 min read
The Raft algorithm is language-agnostic, but the runtime underneath it is not. GC pauses, CPU scheduling, and memory models shape which implementation strategies are even possible.
Read more โ