Posts
Things I’ve written that are long enough to deserve an introduction. Mostly backend engineering, occasional detour into photography and espresso machines.
-
The io.Reader pattern I keep getting wrong
Short reads, partial reads, and the difference between Read and ReadFull took me far too long to get right
-
Result and Option ergonomics after six months
Coming from Go, I thought Result felt heavy. Six months in, I've changed my mind, and I know why
-
When interfaces in Go bite you at the allocation level
Converting a concrete type to an interface is not free, and in hot paths it can account for a startling share of GC pressure
-
Cargo workspaces saved our monorepo
We were on the verge of splitting our Rust monorepo into separate git repos when workspace inheritance landed and changed the cost calculation
-
The pprof graph that taught me to read assembly
A CPU profile pointed at a line with a simple map lookup, and pprof's disasm view sent me down a real rabbit hole
-
sync.Pool is not a memory pool
A long rant about what sync.Pool actually guarantees, when it helps, and when it just gives you the illusion of helping
-
Reading the Go scheduler traces for the first time
An evening with GODEBUG=schedtrace=1000 taught me more about what my service was actually doing than a month of metrics
-
context.Context is not a cache
A team I consulted with had stuffed request-scoped configuration into context values and it was slowly eating their tail latencies
-
A bad day with Rust lifetimes in Axum middleware
Three hours I'll never get back, but I finally understand why the compiler wanted a static bound and what to do about it
-
Why I stopped reaching for sync.Map
sync.Map looks like a drop-in replacement for a map with a mutex, but for most workloads it's slower and harder to reason about
-
The goroutine leak I didn't notice for six weeks
A slow creep in our billing service's memory graph turned out to be goroutines blocked on a channel nobody was draining