my tech notes

Notes on backend, infrastructure, and the occasional rabbit hole.

Tuning Postgres connection pooling with PgBouncer

A short write-up on transaction vs. session pooling, prepared-statement gotchas, and the settings that actually mattered when I moved a busy service behind PgBouncer.

Cutting Docker image size: from 1.2 GB to 90 MB

Multi-stage builds, distroless base images, and why your node_modules is almost certainly the culprit.

A practical intro to systemd timers (instead of cron)

cron works, but systemd timers give you logging, dependency ordering, and randomized delays for free. Here is the setup I now use everywhere.

Reading EXPLAIN ANALYZE without losing your mind

How I finally learned to read the query plan one node at a time, and the three things I check first when a query is slow.