Recent entries
databases
go
concurrency
We replaced a mutex-guarded queue with a single-producer/single-consumer ring and
watched p99 latency drop by half. The catch was memory ordering — atomic.Load
with the wrong fence gives you a buffer that is correct only on x86.
linux
networking
Edge-triggered mode promises fewer syscalls and delivers a parade of subtle bugs if
you forget to drain the socket. A short field guide to EPOLLET, partial
reads, and why your server hangs at exactly 1,024 connections.
rust
parsing
performance
Borrowing slices straight out of the input buffer felt clever until I benchmarked it.
The lesson: &str lifetimes are free, but the allocator was never the
bottleneck — the line-by-line UTF-8 validation was.
observability
postgres
A 40ms query became 4 seconds overnight and nobody touched the code. The culprit was a
planner regression after autovacuum reset the statistics. Here is how I read
EXPLAIN (ANALYZE, BUFFERS) to find the lie in the row estimates.
distributed-systems
testing
Flaky failures are just non-determinism you have not pinned down yet. By feeding a seeded
clock and a controllable network into the same code path, a heisenbug that surfaced
monthly became reproducible on every run with --seed 41.