With lock_timeout equal to statement_timeout (5 s) every request queued behind a migration waiting for its lock failed with 503 together with the migration. A 2 s lock timeout lets the queue proceed once the migration gives up. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>