@warlock.js/queue 5.23.2 → 5.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/CHANGELOG.md +97 -91
  2. package/package.json +3 -3
package/CHANGELOG.md CHANGED
@@ -1,9 +1,15 @@
1
- # Changelog — @warlock.js/queue
2
-
3
- All notable changes to `@warlock.js/queue` are documented in this file.
4
-
5
- The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/). `@warlock.js/*` packages are released in lockstep — every package shares the same version number, so a version below may list only the changes that affected this package.
6
-
1
+ # Changelog — @warlock.js/queue
2
+
3
+ All notable changes to `@warlock.js/queue` are documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/). `@warlock.js/*` packages are released in lockstep — every package shares the same version number, so a version below may list only the changes that affected this package.
6
+
7
+ ## 5.24.0 - 2026-09-27
8
+
9
+ ### Changed
10
+
11
+ - Lockstep release; package APIs are unchanged.
12
+
7
13
  ## 5.23.2 - 2026-09-26
8
14
 
9
15
  ### Changed
@@ -16,88 +22,88 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
16
22
 
17
23
  - Lockstep patch release; package APIs are unchanged.
18
24
 
19
- ## 5.23.0 - 2026-09-25
20
-
21
- ### Added
22
-
23
- - `defineQueueContext()` / `setQueueContext()`: capture ambient state (tenant, request id) at `dispatch` and restore it around the job handler. The captured value travels in a versioned envelope; jobs without one still run. Exposed as `ctx.context`. Opt a job out with `context: false`.
24
- - `UnrecoverableJobError`: throw it from a handler or `restore` to fail the job permanently (mapped to BullMQ's `UnrecoverableError`).
25
-
26
- ## 5.22.1 - 2026-09-25
27
-
28
- ### Changed
29
-
30
- - Lockstep patch release; package APIs are unchanged.
31
-
32
- ## 5.22.0 - 2026-09-25
33
-
34
- ### Changed
35
-
36
- - Lockstep release maintenance and dependency refresh.
37
-
38
- ## 5.21.0 - 2026-09-25
39
-
40
- ### Changed
41
-
42
- - Lockstep release maintenance and dependency refresh.
43
- ## 5.20.0 - 2026-09-24
44
-
45
- ### Changed
46
-
47
- - Added a package-level skill index and clearer discovery descriptions for grouped agent guidance.
48
-
49
- ## 5.19.0 - 2026-09-23
50
-
51
- ### Changed
52
-
53
- - Refined package skill-discovery descriptions and regenerated the llms projections.
54
-
55
- ## 5.16.0 - 2026-09-18
56
-
57
- ### Fixed
58
-
59
- - The failed-jobs dashboard skill sample now includes the connection config and the `authMiddleware` import.
60
-
61
- ## 5.15.0 - 2026-09-18
62
-
63
- ### BREAKING
64
-
65
- - Removed `@warlock.js/queue/notifications` (`queueNotificationDispatcher`), deprecated in 5.14. Use `bullmqQueue()` from `@warlock.js/notifications` instead. The `@warlock.js/notifications` peer dependency is also dropped, since this was the only thing in the package that needed it.
66
-
67
- ### Fixed
68
-
69
- - The dashboard guard now ends the request explicitly when a middleware short-circuits, instead of leaving it to Fastify noticing the reply was already sent. The adapter has always returned a "handled" boolean for this; the hook discarded it, so whether an unauthenticated caller reached the dashboard depended on write ordering — a guard answering asynchronously could lose that race.
70
-
71
- ## 5.14.0 - 2026-09-17
72
-
73
- ### Added
74
-
75
- - `dashboard: { enabled, path, middleware }` in `src/config/queue.ts`: the queue connector mounts Bull Board at boot, guarded by the given middleware.
76
- - `QueueDashboardUnguardedError`: in production the dashboard refuses to mount without guard middleware, since it can retry and delete jobs.
77
- - `queueDashboard()` accepts a `middleware` option.
78
-
79
- ### Deprecated
80
-
81
- - `@warlock.js/queue/notifications` (`queueNotificationDispatcher`): use `bullmqQueue()` from `@warlock.js/notifications`. It still works in 5.14, warns once, and is removed in the next release.
82
-
83
- ### Fixed
84
-
85
- - The connector registers the queue config when it mounts the dashboard at boot, so an app whose only queue usage is the dashboard no longer fails to start with `QueueNotConfiguredError`.
86
- - `find(id)` no longer returns a completed job with `result: null` and `attemptsMade: 0` when the job finishes mid-read.
87
-
88
- ## 5.13.0 - 2026-09-17
89
-
90
- ### Added
91
-
92
- - New package: durable background jobs on BullMQ + Redis. Redis is required.
93
- - `defineJob({ name, queue, attempts, backoff, removeOnComplete, removeOnFail, handle(payload, ctx) })` returns a typed job with `dispatch(payload, { delay, priority, jobId, attempts, backoff })` and `find(id)`.
94
- - Job context: `id`, `name`, `queue`, `attempt`, `maxAttempts`, `progress(value)`, `log(line)`.
95
- - `failedJobs({ queue, start, end })` and `retryFailedJob(id, { queue })`.
96
- - `queueConnector()` for `warlock.config.ts > connectors`: reads the `queue` config key, starts workers in the app process (turn off with `workers.enabled: false`), and on shutdown waits for active jobs up to `workers.shutdownTimeout` before closing.
97
- - `setQueueConfig`, `startWorkers`, `closeQueue` for scripts, tests and worker-only processes.
98
- - `@warlock.js/queue/notifications`: `queueNotificationDispatcher()` sends `@warlock.js/notifications` `.queue()` deliveries through BullMQ, with retries and `delay` support.
99
- - `queueDashboard(server, { basePath })`: mounts bull-board on Warlock's Fastify server. `@bull-board/api` and `@bull-board/fastify` are optional peers, loaded only when it is called; a missing one throws `QueueDashboardDependencyError`.
100
-
101
- ### Fixed
102
-
103
- - Portable `typecheck` script: runs against this package's own `typescript` devDependency instead of relying on a hoisted binary from elsewhere in the workspace.
25
+ ## 5.23.0 - 2026-09-25
26
+
27
+ ### Added
28
+
29
+ - `defineQueueContext()` / `setQueueContext()`: capture ambient state (tenant, request id) at `dispatch` and restore it around the job handler. The captured value travels in a versioned envelope; jobs without one still run. Exposed as `ctx.context`. Opt a job out with `context: false`.
30
+ - `UnrecoverableJobError`: throw it from a handler or `restore` to fail the job permanently (mapped to BullMQ's `UnrecoverableError`).
31
+
32
+ ## 5.22.1 - 2026-09-25
33
+
34
+ ### Changed
35
+
36
+ - Lockstep patch release; package APIs are unchanged.
37
+
38
+ ## 5.22.0 - 2026-09-25
39
+
40
+ ### Changed
41
+
42
+ - Lockstep release maintenance and dependency refresh.
43
+
44
+ ## 5.21.0 - 2026-09-25
45
+
46
+ ### Changed
47
+
48
+ - Lockstep release maintenance and dependency refresh.
49
+ ## 5.20.0 - 2026-09-24
50
+
51
+ ### Changed
52
+
53
+ - Added a package-level skill index and clearer discovery descriptions for grouped agent guidance.
54
+
55
+ ## 5.19.0 - 2026-09-23
56
+
57
+ ### Changed
58
+
59
+ - Refined package skill-discovery descriptions and regenerated the llms projections.
60
+
61
+ ## 5.16.0 - 2026-09-18
62
+
63
+ ### Fixed
64
+
65
+ - The failed-jobs dashboard skill sample now includes the connection config and the `authMiddleware` import.
66
+
67
+ ## 5.15.0 - 2026-09-18
68
+
69
+ ### BREAKING
70
+
71
+ - Removed `@warlock.js/queue/notifications` (`queueNotificationDispatcher`), deprecated in 5.14. Use `bullmqQueue()` from `@warlock.js/notifications` instead. The `@warlock.js/notifications` peer dependency is also dropped, since this was the only thing in the package that needed it.
72
+
73
+ ### Fixed
74
+
75
+ - The dashboard guard now ends the request explicitly when a middleware short-circuits, instead of leaving it to Fastify noticing the reply was already sent. The adapter has always returned a "handled" boolean for this; the hook discarded it, so whether an unauthenticated caller reached the dashboard depended on write ordering — a guard answering asynchronously could lose that race.
76
+
77
+ ## 5.14.0 - 2026-09-17
78
+
79
+ ### Added
80
+
81
+ - `dashboard: { enabled, path, middleware }` in `src/config/queue.ts`: the queue connector mounts Bull Board at boot, guarded by the given middleware.
82
+ - `QueueDashboardUnguardedError`: in production the dashboard refuses to mount without guard middleware, since it can retry and delete jobs.
83
+ - `queueDashboard()` accepts a `middleware` option.
84
+
85
+ ### Deprecated
86
+
87
+ - `@warlock.js/queue/notifications` (`queueNotificationDispatcher`): use `bullmqQueue()` from `@warlock.js/notifications`. It still works in 5.14, warns once, and is removed in the next release.
88
+
89
+ ### Fixed
90
+
91
+ - The connector registers the queue config when it mounts the dashboard at boot, so an app whose only queue usage is the dashboard no longer fails to start with `QueueNotConfiguredError`.
92
+ - `find(id)` no longer returns a completed job with `result: null` and `attemptsMade: 0` when the job finishes mid-read.
93
+
94
+ ## 5.13.0 - 2026-09-17
95
+
96
+ ### Added
97
+
98
+ - New package: durable background jobs on BullMQ + Redis. Redis is required.
99
+ - `defineJob({ name, queue, attempts, backoff, removeOnComplete, removeOnFail, handle(payload, ctx) })` returns a typed job with `dispatch(payload, { delay, priority, jobId, attempts, backoff })` and `find(id)`.
100
+ - Job context: `id`, `name`, `queue`, `attempt`, `maxAttempts`, `progress(value)`, `log(line)`.
101
+ - `failedJobs({ queue, start, end })` and `retryFailedJob(id, { queue })`.
102
+ - `queueConnector()` for `warlock.config.ts > connectors`: reads the `queue` config key, starts workers in the app process (turn off with `workers.enabled: false`), and on shutdown waits for active jobs up to `workers.shutdownTimeout` before closing.
103
+ - `setQueueConfig`, `startWorkers`, `closeQueue` for scripts, tests and worker-only processes.
104
+ - `@warlock.js/queue/notifications`: `queueNotificationDispatcher()` sends `@warlock.js/notifications` `.queue()` deliveries through BullMQ, with retries and `delay` support.
105
+ - `queueDashboard(server, { basePath })`: mounts bull-board on Warlock's Fastify server. `@bull-board/api` and `@bull-board/fastify` are optional peers, loaded only when it is called; a missing one throws `QueueDashboardDependencyError`.
106
+
107
+ ### Fixed
108
+
109
+ - Portable `typecheck` script: runs against this package's own `typescript` devDependency instead of relying on a hoisted binary from elsewhere in the workspace.
package/package.json CHANGED
@@ -11,8 +11,8 @@
11
11
  "peerDependencies": {
12
12
  "@bull-board/api": "^9.0.0",
13
13
  "@bull-board/fastify": "^9.0.0",
14
- "@warlock.js/core": "5.23.2",
15
- "@warlock.js/logger": "5.23.2"
14
+ "@warlock.js/core": "5.24.0",
15
+ "@warlock.js/logger": "5.24.0"
16
16
  },
17
17
  "peerDependenciesMeta": {
18
18
  "@bull-board/api": {
@@ -37,7 +37,7 @@
37
37
  ],
38
38
  "author": "hassanzohdy",
39
39
  "license": "MIT",
40
- "version": "5.23.2",
40
+ "version": "5.24.0",
41
41
  "main": "./cjs/index.cjs",
42
42
  "module": "./esm/index.mjs",
43
43
  "types": "./esm/index.d.mts",