
I Replaced Our Puppeteer Cluster with a Single REST Endpoint — Here's What I Built
It didn't announce itself dramatically. No alarms, no pages, no production fire. Just a support ticket on a Tuesday morning: "Hey, I signed up yesterday and never received my invoice. Can you resend it?" We checked. The invoice had never generated. We restarted the PDF service, the next few invoices went out fine, and we closed the ticket and moved on. A week later, another one. Then two in the same day. Then we pulled the logs and realised this had been happening quietly for over a month — a small but steady trickle of failed invoice generations that nobody had noticed because most customers just didn't say anything. We were running Puppeteer in a Docker container to generate PDF invoices — a setup that had worked perfectly in staging, worked fine in the first couple of months of production, and then slowly, quietly, started falling apart. The culprit: a memory leak we couldn't fully pin down. The Chromium process would balloon over time, the pod would get OOM-killed, and invoice gene
Continue reading on Dev.to Webdev
Opens in a new tab
