Skip to content
Get started
Get started
bunqueue v2.6.71
View Markdown
blog · release

bunqueue v2.6.71

Fixes 6 bugs. BullMQ v5 prioritized state, bullMQ v5 waiting-children state, failParentOnFailure, flow atomicity and more.

bun add bunqueue@2.6.71
npm install bunqueue@2.6.71
bun add bunqueue@latest

Jobs with priority > 0 now report state 'prioritized' instead of 'waiting', matching BullMQ v5 exactly. Affects getJobState(), getJobCounts(), Prometheus metrics, cloud snapshot, SSE/WebSocket events, and MCP adapter.

Parent jobs in flows correctly report 'waiting-children' state while waiting for child jobs to complete.

When a child job terminally fails with failParentOnFailure: true, the parent job is automatically moved to failed state. Handles race conditions where child fails before parent linkage is established.

FlowProducer.add() and addBulk() now automatically roll back all created jobs if any part of the flow fails during creation.

Pass per-queue default job options as second argument to flow.add(flowJob, { queuesOptions: { queueName: { attempts: 5 } } }).

BullMQ v5 compatible. close() returns Promise<void>, closing property tracks shutdown, disconnect() alias.

moveActiveToWait, changeWaitingDelay, moveToWaitingChildren state transitions with proper resource cleanup (concurrency slots, unique keys, group locks).

  • Documentation: Updated state machine diagrams, API types, FlowProducer guide, migration guide with BullMQ v5 parity tables, cloud contract with new snapshot fields.
  • TOCTOU in moveParentToFailed: Re-checks jobIndex inside write lock to prevent duplicate DLQ entries when multiple children with failParentOnFailure fail concurrently.
  • Unhandled promise rejections: moveParentToFailed calls now have .catch() handlers instead of fire-and-forget void.
  • SQLite queryJobs(state='prioritized'): Translates 'prioritized' to WHERE state='waiting' AND priority > 0 since SQLite never stores ‘prioritized’ as a state value.
  • moveActiveToWait resource leak: Now calls releaseJobResources() to free concurrency/uniqueKey/group slots before re-queueing.
  • Move operations handle prioritized state: moveJobToWait and moveJobToDelayed now correctly handle jobs in 'prioritized' state.
  • Cloud snapshot: Added prioritized to stats and per-queue data. Per-queue data now uses failed instead of dlq (BullMQ v5 compatible).

← bunqueue v2.6.67 · Release on GitHub · Commits since v2.6.67 · Full changelog · All posts