From 1254d9f8f07d3be91ab9c8776ca9135a56adc5d0 Mon Sep 17 00:00:00 2001 From: Quentin Gliech Date: Mon, 19 Jan 2026 15:44:22 +0100 Subject: [PATCH] Mark the next attempt foreign key as initially not valid --- .../20260116000003_queue_jobs_next_attempt_set_null.sql | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/storage-pg/migrations/20260116000003_queue_jobs_next_attempt_set_null.sql b/crates/storage-pg/migrations/20260116000003_queue_jobs_next_attempt_set_null.sql index a9c1a47b2..c94934500 100644 --- a/crates/storage-pg/migrations/20260116000003_queue_jobs_next_attempt_set_null.sql +++ b/crates/storage-pg/migrations/20260116000003_queue_jobs_next_attempt_set_null.sql @@ -10,4 +10,5 @@ ALTER TABLE queue_jobs ADD CONSTRAINT queue_jobs_next_attempt_id_fkey FOREIGN KEY (next_attempt_id) REFERENCES queue_jobs (queue_job_id) - ON DELETE SET NULL; + ON DELETE SET NULL + NOT VALID;