Skip to content

Fix GoodJob advisory lock statement timeout errors#123

Merged
xrendan merged 1 commit intomainfrom
fix/goodjob-advisory-lock-timeout
Mar 27, 2026
Merged

Fix GoodJob advisory lock statement timeout errors#123
xrendan merged 1 commit intomainfrom
fix/goodjob-advisory-lock-timeout

Conversation

@xrendan
Copy link
Copy Markdown
Member

@xrendan xrendan commented Mar 27, 2026

Summary

  • Disables Supabase's default statement timeout (4 min) on production database connections
  • Fixes 57014 (query_canceled) errors on GoodJob's pg_advisory_xact_lock queries
  • GoodJob relies on advisory locks for run-once job safety; these locks need to wait without a timeout ceiling

Test plan

  • Deploy and verify no more 57014 errors in Supabase logs
  • Confirm GoodJob cron jobs execute successfully

🤖 Generated with Claude Code

…errors

Supabase's default statement timeout (4 min) kills GoodJob's pg_advisory_xact_lock
queries, causing 57014 errors. Setting statement_timeout to 0 on the Rails connection
lets advisory locks wait as long as needed.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@xrendan xrendan merged commit 1e4cb91 into main Mar 27, 2026
1 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant