v1.1.1
PgQueuer v1.1.1
Widens the id primary keys on queue, statistics, and schedules from
int4 to BIGINT (#676, closes #671).
Fixes
idcolumns widened toBIGINT: thequeue,statistics, and
schedulesprimary keys wereint4 SERIAL, capped at ~2.1 billion. The
sequence never reuses values, so a long-lived deployment could exhaust it and
fail everyenqueue. Fresh installs now useBIGSERIAL.pgq upgradewidens
existingint4columns and their sequences toBIGINTin place. The
migration is idempotent (guarded on column/sequence type) and safe to re-run.
Upgrade notes
ACCESS EXCLUSIVE lock. Widening int4 to
BIGINT rewrites the table and rebuilds its indexes, blocking enqueues,
dequeues, and SELECTs until it finishes. Time scales with row count; on a
large or bloated queue this can stall the queue for seconds to minutes.
- Run
pgq upgradeduring a maintenance window or low-traffic period, or - Run
pgq upgrade --no-widen-idto apply the other migrations and skip the
widen, then widen out-of-band.
For a zero-downtime widen on a large table, see #671
and the postgres.ai runbook How to redefine a PK without
downtime.
Full Changelog: v1.1.0...v1.1.1