@warlock.js/scheduler 5.25.0 → 5.26.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.
- package/CHANGELOG.md +6 -0
- package/llms-full.txt +11 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,12 @@ All notable changes to `@warlock.js/scheduler` are documented in this file.
|
|
|
4
4
|
|
|
5
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
6
|
|
|
7
|
+
## 5.26.0 - 2026-09-30
|
|
8
|
+
|
|
9
|
+
### Changed
|
|
10
|
+
|
|
11
|
+
- Lockstep release; package APIs are unchanged.
|
|
12
|
+
|
|
7
13
|
## 5.25.0 - 2026-09-28
|
|
8
14
|
|
|
9
15
|
### Changed
|
package/llms-full.txt
CHANGED
|
@@ -877,6 +877,17 @@ process.on("SIGTERM", async () => {
|
|
|
877
877
|
|
|
878
878
|
> Registering jobs alone runs nothing — you must call `scheduler.start()`. As a safety net, in development (`NODE_ENV !== "production"`) the scheduler logs a one-shot `console.warn` if jobs are registered but `start()` is never called.
|
|
879
879
|
|
|
880
|
+
## Run scheduled jobs inside a context
|
|
881
|
+
|
|
882
|
+
Use `scheduler.around(hook)` to wrap every callback execution — each retry attempt too — for example in an `AsyncLocalStorage` context:
|
|
883
|
+
|
|
884
|
+
```ts
|
|
885
|
+
scheduler.around((job, run) => storage.run({ job: job.name }, run));
|
|
886
|
+
```
|
|
887
|
+
|
|
888
|
+
- First registered hook is the outermost; `around` returns an unsubscribe function.
|
|
889
|
+
- A hook that never calls `run` skips the execution (`job:skip`, `result.skipped`); a hook that throws is treated as a callback error (retry/error path applies).
|
|
890
|
+
|
|
880
891
|
## Pick a skill
|
|
881
892
|
|
|
882
893
|
| If the task is about… | Load |
|
package/package.json
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"dayjs": "^1.11.19"
|
|
9
9
|
},
|
|
10
10
|
"peerDependencies": {
|
|
11
|
-
"@warlock.js/cache": "5.
|
|
11
|
+
"@warlock.js/cache": "5.26.0"
|
|
12
12
|
},
|
|
13
13
|
"peerDependenciesMeta": {
|
|
14
14
|
"@warlock.js/cache": {
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
],
|
|
34
34
|
"author": "hassanzohdy",
|
|
35
35
|
"license": "MIT",
|
|
36
|
-
"version": "5.
|
|
36
|
+
"version": "5.26.0",
|
|
37
37
|
"main": "./cjs/index.cjs",
|
|
38
38
|
"module": "./esm/index.mjs",
|
|
39
39
|
"types": "./esm/index.d.mts",
|