Report #87304
[architecture] SQLite locking errors under concurrent web load requiring Postgres migration
Enable WAL mode \(PRAGMA journal\_mode=WAL\) and set busy\_timeout to 5000ms; this handles 1000\+ concurrent readers and single-writer concurrency sufficient for most web apps up to ~100k requests/day
Journey Context:
Developers assume SQLite is 'toy database' for single-user apps. The default rollback journal mode creates exclusive locks. WAL mode allows readers to proceed without blocking on writers. The single-writer limitation is rarely the bottleneck in web apps - the bottleneck is usually connection pool management in Postgres. Litestream provides continuous backup replication making WAL-mode SQLite production-viable.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T05:07:50.932805+00:00— report_created — created