Writing
Notes on building things that hold up
Don't use a slug as an identity
Why linking records through a field users can edit breaks, and how stable group IDs, window-function backfills and partial unique indexes fix it.
Oct 16, 2026 · 9 min read
Making a 3-second list endpoint answer in 25 ms
How building only the visible page, set-based access checks and one misplaced cast took a PostgreSQL list query from seconds to milliseconds.
Oct 3, 2026 · 11 min read
Never call the outside world before you commit
When you write to your database and call another system, the order decides what you can recover from. Here's why, and the patterns that keep both sides in agreement.
Sep 30, 2026 · 10 min read
Keyset pagination and fuzzy search in PostgreSQL
Why OFFSET gets slower with every page, how keyset cursors and matching indexes fix it, and how to make pg_trgm search typo-tolerant and fast.
Sep 22, 2026 · 10 min read
Never edit an applied migration
How migration tools track what has run, why editing an applied file causes schema drift CI can't see, and how to fix it forward.
Jul 16, 2026 · 8 min read
Building a live HLS packager in Go
Why copying a media server's HLS output failed, and the process, locking and codec bugs I fixed while packaging live streams myself.
Jun 5, 2026 · 11 min read
Rolled a six, moved every token: keeping multiplayer state authoritative
How leftover input, partial state broadcasts and update-only UIs add up to exploits and deadlocks in a real-time game, and how to fix them.
May 19, 2026 · 7 min read
Integrating eSewa v2: form POSTs, signatures and money in paisa
How hosted payment gateways work, why you must verify payments server to server, and the details that make eSewa v2 payments succeed or quietly fail.
Apr 26, 2026 · 8 min read
Debugging a WebSocket hub that froze under load
How one shared Go map, an unbuffered channel and a lock in the wrong place stalled real-time chat, and how I reproduced it.
Jan 26, 2026 · 8 min read