// Articles
Guides, tutorials, and comparisons to help you build better backend applications.
What Cloud Run's 'failed to start and listen on the port defined by the PORT environment variable' error means, the six causes behind it, and how to find which one hit your revision.
Let carriers book dock doors without double bookings: slot availability from warehouse hours, a Postgres exclusion constraint on time ranges, bookings that cannot overlap even under concurrent requests, gate check-in, no-show detection on a schedule and events for carriers, in TypeScript with Encore.
Track clinician licenses, DEA registrations, board certifications and malpractice coverage: NPI checks against the NPPES registry, evidence stored for every verification, monthly OIG exclusion screening, expiry alerts and a clearance rule scheduling can trust, in Go with Encore.
Accrue interest on savings and deposit accounts every day from ledger balances, keep sub-cent precision without floating point, make reruns safe, post interest monthly with the rounding remainder carried forward, and schedule it all in TypeScript with Encore.
Sell ebooks, templates, software and other files: private storage, entitlements granted when an order is paid, download links with expiry and download limits, short-lived signed URLs, revocation on refund and link resends, in Go with Encore.
Move a Neon database into Cloud SQL for PostgreSQL in your own GCP project: dump over the direct connection, strip Neon roles, Neon Auth references and Neon-only extensions, restore through a private connection, and choose between a write freeze and logical replication for the cutover.
Test publishers, subscribers, retries and the full flow of an event-driven backend on your laptop: what each layer proves, where cloud emulators drift from production, and a Go example with a publisher test, an idempotent subscriber test and a local end-to-end run.
Why preview environments that share a staging database break each other, how database-per-PR, schema-per-PR and copy-on-write clones compare, how to seed and clean up preview databases, and a Go example where every preview environment gets its own migrated, seeded Postgres database.
What a database mock verifies, which bugs only show up against real Postgres, why SQLite is a poor stand-in, and how to make real-database tests fast enough to run on every change, with a Go example that tests a unique index against an isolated test database.
A GitHub Actions workflow that deploys every pull request to its own Cloud Run service with its own Cloud SQL database, comments the URL, and tears everything down when the pull request closes, plus the fork, cost and config pitfalls to plan for.
Set up Claude Code hooks for a backend repo: a type check after every edit, a Stop hook that runs the tests against local infrastructure before Claude finishes, and a PreToolUse hook that keeps cloud CLIs out of the session, with an Encore example.
What the sidecar pattern is, the jobs sidecars usually do in Kubernetes, native sidecar containers, the costs in memory, startup ordering and upgrades, and the alternatives: libraries in the process, node agents and sidecar-less meshes.