Files
Simon Pinfold a35fcbac26 fix(db): wait briefly for the database lock at startup (#16602)
* fix(db): wait briefly for the database lock at startup

A relaunch can start while the previous process is still exiting and
holding the lock. Wait up to 5 seconds for it to be released before
treating the database as in use, and log how long the wait took. The
lock is never taken from a holder.

* fix(db): log the lock wait at info without guessing its cause

* fix(db): say when startup waits for the database lock

Log once before the wait instead of after it, so a lock that stays held
explains the pause before the error. Document the wait in the docstring,
and make the wait test release the lock only after the wait has started.
2026-09-28 19:46:19 -07:00
..