@dudousxd/nestjs-durable 0.50.0 → 0.51.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/dist/index.cjs +18 -28
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +5 -3
- package/dist/index.d.ts +5 -3
- package/dist/index.js +20 -34
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/skills/durable-workflows/SKILL.md +5 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dudousxd/nestjs-durable",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.51.0",
|
|
4
4
|
"description": "Durable workflows for NestJS — module, decorators, discovery and boot recovery",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Davide Carvalho",
|
|
@@ -68,10 +68,10 @@
|
|
|
68
68
|
"@dudousxd/nestjs-diagnostics": "0.5.0",
|
|
69
69
|
"@tanstack/intent": "0.4.0",
|
|
70
70
|
"@dudousxd/durable-worker": "0.11.2",
|
|
71
|
-
"@dudousxd/nestjs-durable-
|
|
71
|
+
"@dudousxd/nestjs-durable-dashboard": "0.52.0",
|
|
72
|
+
"@dudousxd/nestjs-durable-core": "^0.83.0",
|
|
72
73
|
"@dudousxd/nestjs-durable-testing": "^0.21.0",
|
|
73
74
|
"@dudousxd/nestjs-durable-transport-bullmq": "0.22.4",
|
|
74
|
-
"@dudousxd/nestjs-durable-dashboard": "0.52.0",
|
|
75
75
|
"@dudousxd/nestjs-durable-transport-event-emitter": "^0.5.3"
|
|
76
76
|
},
|
|
77
77
|
"module": "./dist/index.js",
|
|
@@ -98,7 +98,9 @@ const out = await ctx.step<ProcResult>('processing:proc', input);
|
|
|
98
98
|
side has no `@Step` of its own. `@Step({ name?, input?, output?, retries?, backoff?, backoffMs?,
|
|
99
99
|
backoffMaxMs?, jitter?, timeoutMs? })` additionally opts into RUNTIME validation (a Standard Schema such as zod, or a class-validator DTO
|
|
100
100
|
class) (`input`
|
|
101
|
-
validates before the method runs, `output` validates its return value
|
|
101
|
+
validates before the method runs, `output` validates its return value; a mismatch throws a
|
|
102
|
+
`SchemaValidationError` from core, a `FatalError` with code `invalid_input` / `invalid_output` and
|
|
103
|
+
`details.issues`) and a def-level durable-retry
|
|
102
104
|
policy — a bare `@Step()` skips both and dispatches with no retry/timeout.
|
|
103
105
|
|
|
104
106
|
Every dispatched step is a first-class checkpoint: on crash/replay a `completed` one returns its
|
|
@@ -309,7 +311,8 @@ async invalid(ctx: WorkflowCtx, failure: OnErrorInput<Line>): Promise<LineResult
|
|
|
309
311
|
```
|
|
310
312
|
|
|
311
313
|
`error.details` is the third argument of `FatalError(message, code, details)` (e.g. validation
|
|
312
|
-
issues
|
|
314
|
+
issues; a `SchemaValidationError` carries `{ issues }`, and `@OnError(SchemaValidationError)` catches
|
|
315
|
+
`invalid_input`, `invalid_output` and `schema_validation`). Retrying the run runs its body again; a new failure goes to a new handler run.
|
|
313
316
|
It matches on `code`, never `instanceof`, must return `run`'s output type, and never sees
|
|
314
317
|
cancellation (a `cancelled` run never routes), `nested_workflow_call` ctx misuse, or `non_determinism`
|
|
315
318
|
(`NonDeterminismError` carries `code: 'non_determinism'`). `@Workflow({ onError: [{ code, workflow }] })` routes to another workflow.
|