@dudousxd/nestjs-durable-core 0.27.0 → 0.28.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 (113) hide show
  1. package/LICENSE +21 -0
  2. package/dist/index.cjs +3923 -0
  3. package/dist/index.cjs.map +1 -0
  4. package/dist/index.d.cts +2044 -0
  5. package/dist/index.d.ts +2044 -20
  6. package/dist/index.js +3857 -38
  7. package/dist/index.js.map +1 -1
  8. package/package.json +19 -5
  9. package/dist/backoff.d.ts +0 -5
  10. package/dist/backoff.d.ts.map +0 -1
  11. package/dist/backoff.js +0 -14
  12. package/dist/backoff.js.map +0 -1
  13. package/dist/checkpoints.d.ts +0 -17
  14. package/dist/checkpoints.d.ts.map +0 -1
  15. package/dist/checkpoints.js +0 -28
  16. package/dist/checkpoints.js.map +0 -1
  17. package/dist/codec-state-store.d.ts +0 -57
  18. package/dist/codec-state-store.d.ts.map +0 -1
  19. package/dist/codec-state-store.js +0 -111
  20. package/dist/codec-state-store.js.map +0 -1
  21. package/dist/completion.d.ts +0 -15
  22. package/dist/completion.d.ts.map +0 -1
  23. package/dist/completion.js +0 -13
  24. package/dist/completion.js.map +0 -1
  25. package/dist/duration.d.ts +0 -6
  26. package/dist/duration.d.ts.map +0 -1
  27. package/dist/duration.js +0 -42
  28. package/dist/duration.js.map +0 -1
  29. package/dist/engine.d.ts +0 -525
  30. package/dist/engine.d.ts.map +0 -1
  31. package/dist/engine.js +0 -1773
  32. package/dist/engine.js.map +0 -1
  33. package/dist/entities.d.ts +0 -44
  34. package/dist/entities.d.ts.map +0 -1
  35. package/dist/entities.js +0 -68
  36. package/dist/entities.js.map +0 -1
  37. package/dist/errors.d.ts +0 -56
  38. package/dist/errors.d.ts.map +0 -1
  39. package/dist/errors.js +0 -93
  40. package/dist/errors.js.map +0 -1
  41. package/dist/event-accumulators.d.ts +0 -39
  42. package/dist/event-accumulators.d.ts.map +0 -1
  43. package/dist/event-accumulators.js +0 -74
  44. package/dist/event-accumulators.js.map +0 -1
  45. package/dist/events.d.ts +0 -9
  46. package/dist/events.d.ts.map +0 -1
  47. package/dist/events.js +0 -41
  48. package/dist/events.js.map +0 -1
  49. package/dist/index.d.ts.map +0 -1
  50. package/dist/interfaces.d.ts +0 -830
  51. package/dist/interfaces.d.ts.map +0 -1
  52. package/dist/interfaces.js +0 -3
  53. package/dist/interfaces.js.map +0 -1
  54. package/dist/metrics.d.ts +0 -44
  55. package/dist/metrics.d.ts.map +0 -1
  56. package/dist/metrics.js +0 -76
  57. package/dist/metrics.js.map +0 -1
  58. package/dist/protocol.d.ts +0 -17
  59. package/dist/protocol.d.ts.map +0 -1
  60. package/dist/protocol.js +0 -53
  61. package/dist/protocol.js.map +0 -1
  62. package/dist/queue.d.ts +0 -48
  63. package/dist/queue.d.ts.map +0 -1
  64. package/dist/queue.js +0 -45
  65. package/dist/queue.js.map +0 -1
  66. package/dist/remote-step-factory.d.ts +0 -15
  67. package/dist/remote-step-factory.d.ts.map +0 -1
  68. package/dist/remote-step-factory.js +0 -15
  69. package/dist/remote-step-factory.js.map +0 -1
  70. package/dist/remote-workflow-executor.d.ts +0 -24
  71. package/dist/remote-workflow-executor.d.ts.map +0 -1
  72. package/dist/remote-workflow-executor.js +0 -73
  73. package/dist/remote-workflow-executor.js.map +0 -1
  74. package/dist/scheduler.d.ts +0 -42
  75. package/dist/scheduler.d.ts.map +0 -1
  76. package/dist/scheduler.js +0 -70
  77. package/dist/scheduler.js.map +0 -1
  78. package/dist/search-attributes.d.ts +0 -17
  79. package/dist/search-attributes.d.ts.map +0 -1
  80. package/dist/search-attributes.js +0 -47
  81. package/dist/search-attributes.js.map +0 -1
  82. package/dist/step-logger.d.ts +0 -9
  83. package/dist/step-logger.d.ts.map +0 -1
  84. package/dist/step-logger.js +0 -92
  85. package/dist/step-logger.js.map +0 -1
  86. package/dist/test-helpers.d.ts +0 -11
  87. package/dist/test-helpers.d.ts.map +0 -1
  88. package/dist/test-helpers.js +0 -15
  89. package/dist/test-helpers.js.map +0 -1
  90. package/dist/testing/in-memory-state-store.d.ts +0 -37
  91. package/dist/testing/in-memory-state-store.d.ts.map +0 -1
  92. package/dist/testing/in-memory-state-store.js +0 -134
  93. package/dist/testing/in-memory-state-store.js.map +0 -1
  94. package/dist/testing/in-memory-transport.d.ts +0 -25
  95. package/dist/testing/in-memory-transport.d.ts.map +0 -1
  96. package/dist/testing/in-memory-transport.js +0 -53
  97. package/dist/testing/in-memory-transport.js.map +0 -1
  98. package/dist/tokens.d.ts +0 -8
  99. package/dist/tokens.d.ts.map +0 -1
  100. package/dist/tokens.js +0 -11
  101. package/dist/tokens.js.map +0 -1
  102. package/dist/transport-pool.d.ts +0 -30
  103. package/dist/transport-pool.d.ts.map +0 -1
  104. package/dist/transport-pool.js +0 -86
  105. package/dist/transport-pool.js.map +0 -1
  106. package/dist/workflow-ctx.d.ts +0 -52
  107. package/dist/workflow-ctx.d.ts.map +0 -1
  108. package/dist/workflow-ctx.js +0 -432
  109. package/dist/workflow-ctx.js.map +0 -1
  110. package/dist/workflow-ref.d.ts +0 -34
  111. package/dist/workflow-ref.d.ts.map +0 -1
  112. package/dist/workflow-ref.js +0 -32
  113. package/dist/workflow-ref.js.map +0 -1
@@ -1 +0,0 @@
1
- {"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../src/interfaces.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,KAAK,EAAE,aAAa,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAEvF;;;;;GAKG;AAMH,MAAM,MAAM,SAAS;AACnB,6FAA6F;AAC3F,SAAS,GACT,SAAS,GACT,WAAW,GACX,WAAW,GACX,QAAQ,GACR,WAAW;AACb,uGAAuG;GACrG,MAAM,CAAC;AAEX,+FAA+F;AAC/F,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,iDAAiD;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B,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,kGAAkG;IAClG,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,kDAAkD;IAClD,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,qEAAqE;IACrE,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAED;;;;;;GAMG;AACH,MAAM,MAAM,eAAe,GAAG,CAC5B,UAAU,EAAE,cAAc,EAC1B,IAAI,EAAE,MAAM,OAAO,CAAC,OAAO,CAAC,KACzB,OAAO,CAAC,OAAO,CAAC,CAAC"}
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=interfaces.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"interfaces.js","sourceRoot":"","sources":["../src/interfaces.ts"],"names":[],"mappings":""}
package/dist/metrics.d.ts DELETED
@@ -1,44 +0,0 @@
1
- import type { EngineEvent } from './interfaces';
2
- export interface MetricsSnapshot {
3
- runs: {
4
- started: number;
5
- completed: number;
6
- failed: number;
7
- suspended: number;
8
- };
9
- steps: {
10
- started: number;
11
- completed: number;
12
- failed: number;
13
- };
14
- /** Per-workflow run counters, keyed by workflow name. */
15
- byWorkflow: Record<string, {
16
- started: number;
17
- completed: number;
18
- failed: number;
19
- }>;
20
- /** Sum + count of recorded step durations (ms), for an average. */
21
- stepDuration: {
22
- sumMs: number;
23
- count: number;
24
- };
25
- }
26
- export interface MetricsCollector {
27
- snapshot(): MetricsSnapshot;
28
- /** Prometheus text exposition of the counters — serve this from a `/metrics` endpoint. */
29
- prometheus(): string;
30
- /** Unsubscribe from the engine. */
31
- stop(): void;
32
- }
33
- type Subscribable = {
34
- subscribe(listener: (event: EngineEvent) => void): () => void;
35
- };
36
- /**
37
- * Subscribe to an engine's lifecycle events and accumulate Prometheus-style counters (runs + steps by
38
- * outcome, per-workflow run counts, step-duration sum/count). Dependency-free — call `.prometheus()`
39
- * from your metrics endpoint, or `.snapshot()` for the raw numbers. Counters are per process; scrape
40
- * each instance.
41
- */
42
- export declare function collectMetrics(engine: Subscribable): MetricsCollector;
43
- export {};
44
- //# sourceMappingURL=metrics.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"metrics.d.ts","sourceRoot":"","sources":["../src/metrics.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC;IAChF,KAAK,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC;IAC9D,yDAAyD;IACzD,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IACnF,mEAAmE;IACnE,YAAY,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC;CAChD;AAED,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,IAAI,eAAe,CAAC;IAC5B,0FAA0F;IAC1F,UAAU,IAAI,MAAM,CAAC;IACrB,mCAAmC;IACnC,IAAI,IAAI,IAAI,CAAC;CACd;AAED,KAAK,YAAY,GAAG;IAAE,SAAS,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE,WAAW,KAAK,IAAI,GAAG,MAAM,IAAI,CAAA;CAAE,CAAC;AAEtF;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,MAAM,EAAE,YAAY,GAAG,gBAAgB,CAmErE"}
package/dist/metrics.js DELETED
@@ -1,76 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.collectMetrics = collectMetrics;
4
- /**
5
- * Subscribe to an engine's lifecycle events and accumulate Prometheus-style counters (runs + steps by
6
- * outcome, per-workflow run counts, step-duration sum/count). Dependency-free — call `.prometheus()`
7
- * from your metrics endpoint, or `.snapshot()` for the raw numbers. Counters are per process; scrape
8
- * each instance.
9
- */
10
- function collectMetrics(engine) {
11
- const m = {
12
- runs: { started: 0, completed: 0, failed: 0, suspended: 0 },
13
- steps: { started: 0, completed: 0, failed: 0 },
14
- byWorkflow: {},
15
- stepDuration: { sumMs: 0, count: 0 },
16
- };
17
- const wf = (name) => {
18
- const k = name ?? 'unknown';
19
- return (m.byWorkflow[k] ??= { started: 0, completed: 0, failed: 0 });
20
- };
21
- const stop = engine.subscribe((e) => {
22
- switch (e.type) {
23
- case 'run.started':
24
- m.runs.started += 1;
25
- wf(e.workflow).started += 1;
26
- break;
27
- case 'run.completed':
28
- m.runs.completed += 1;
29
- wf(e.workflow).completed += 1;
30
- break;
31
- case 'run.failed':
32
- m.runs.failed += 1;
33
- wf(e.workflow).failed += 1;
34
- break;
35
- case 'run.suspended':
36
- m.runs.suspended += 1;
37
- break;
38
- case 'step.started':
39
- m.steps.started += 1;
40
- break;
41
- case 'step.completed':
42
- m.steps.completed += 1;
43
- if (e.durationMs != null) {
44
- m.stepDuration.sumMs += e.durationMs;
45
- m.stepDuration.count += 1;
46
- }
47
- break;
48
- case 'step.failed':
49
- m.steps.failed += 1;
50
- break;
51
- }
52
- });
53
- return {
54
- snapshot: () => structuredClone(m),
55
- stop,
56
- prometheus: () => {
57
- const lines = [];
58
- lines.push('# TYPE durable_runs_total counter');
59
- for (const [k, v] of Object.entries(m.runs))
60
- lines.push(`durable_runs_total{event="${k}"} ${v}`);
61
- lines.push('# TYPE durable_steps_total counter');
62
- for (const [k, v] of Object.entries(m.steps))
63
- lines.push(`durable_steps_total{event="${k}"} ${v}`);
64
- lines.push('# TYPE durable_runs_by_workflow_total counter');
65
- for (const [name, v] of Object.entries(m.byWorkflow))
66
- for (const [event, n] of Object.entries(v))
67
- lines.push(`durable_runs_by_workflow_total{workflow="${name}",event="${event}"} ${n}`);
68
- lines.push('# TYPE durable_step_duration_ms_sum counter');
69
- lines.push(`durable_step_duration_ms_sum ${m.stepDuration.sumMs}`);
70
- lines.push('# TYPE durable_step_duration_count counter');
71
- lines.push(`durable_step_duration_count ${m.stepDuration.count}`);
72
- return `${lines.join('\n')}\n`;
73
- },
74
- };
75
- }
76
- //# sourceMappingURL=metrics.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"metrics.js","sourceRoot":"","sources":["../src/metrics.ts"],"names":[],"mappings":";;AA2BA,wCAmEC;AAzED;;;;;GAKG;AACH,SAAgB,cAAc,CAAC,MAAoB;IACjD,MAAM,CAAC,GAAoB;QACzB,IAAI,EAAE,EAAE,OAAO,EAAE,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE;QAC3D,KAAK,EAAE,EAAE,OAAO,EAAE,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE;QAC9C,UAAU,EAAE,EAAE;QACd,YAAY,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE;KACrC,CAAC;IACF,MAAM,EAAE,GAAG,CAAC,IAAa,EAAE,EAAE;QAC3B,MAAM,CAAC,GAAG,IAAI,IAAI,SAAS,CAAC;QAC5B,OAAO,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,KAAK,EAAE,OAAO,EAAE,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC,CAAC;IACvE,CAAC,CAAC;IAEF,MAAM,IAAI,GAAG,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;QAClC,QAAQ,CAA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Canonical step id — the stable identity of a step within a run, used for dedupe and
3
- * correlation. The format is part of the cross-language wire contract (Python builds the same). */
4
- export declare function stepId(runId: string, seq: number): string;
5
- /** Deterministic signal token a breakpoint suspends on — derived from its logical position. Shared
6
- * so `ctx.breakpoint` (which records it) and `engine.continue` (which signals it) agree. */
7
- export declare const breakpointToken: (runId: string, seq: number) => string;
8
- /** A remote-worker step body. The optional `log` records sub-process outcomes and debug/error
9
- * lines that ride back on the result — the TypeScript twin of the Python SDK's `StepContext`. */
10
- export type StepHandler = (input: unknown, log: StepLogger) => Promise<unknown> | unknown;
11
- /**
12
- * Run `handler` for `task` and produce the wire-format {@link StepResult}. Pure (no transport,
13
- * no I/O beyond the handler), so every transport — and any language port — can share the exact
14
- * same completed / failed / no-handler contract instead of re-deriving it.
15
- */
16
- export declare function runStepHandler(task: RemoteTask, handler: StepHandler | undefined): Promise<StepResult>;
17
- //# sourceMappingURL=protocol.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"protocol.d.ts","sourceRoot":"","sources":["../src/protocol.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAa,UAAU,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAGlF;oGACoG;AACpG,wBAAgB,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,CAEzD;AAED;6FAC6F;AAC7F,eAAO,MAAM,eAAe,GAAI,OAAO,MAAM,EAAE,KAAK,MAAM,KAAG,MAA8B,CAAC;AAE5F;kGACkG;AAClG,MAAM,MAAM,WAAW,GAAG,CAAC,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,UAAU,KAAK,OAAO,CAAC,OAAO,CAAC,GAAG,OAAO,CAAC;AAE1F;;;;GAIG;AACH,wBAAsB,cAAc,CAClC,IAAI,EAAE,UAAU,EAChB,OAAO,EAAE,WAAW,GAAG,SAAS,GAC/B,OAAO,CAAC,UAAU,CAAC,CA+BrB"}
package/dist/protocol.js DELETED
@@ -1,53 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.breakpointToken = void 0;
4
- exports.stepId = stepId;
5
- exports.runStepHandler = runStepHandler;
6
- const step_logger_1 = require("./step-logger");
7
- /** Canonical step id — the stable identity of a step within a run, used for dedupe and
8
- * correlation. The format is part of the cross-language wire contract (Python builds the same). */
9
- function stepId(runId, seq) {
10
- return `${runId}:${seq}`;
11
- }
12
- /** Deterministic signal token a breakpoint suspends on — derived from its logical position. Shared
13
- * so `ctx.breakpoint` (which records it) and `engine.continue` (which signals it) agree. */
14
- const breakpointToken = (runId, seq) => `bp:${runId}:${seq}`;
15
- exports.breakpointToken = breakpointToken;
16
- /**
17
- * Run `handler` for `task` and produce the wire-format {@link StepResult}. Pure (no transport,
18
- * no I/O beyond the handler), so every transport — and any language port — can share the exact
19
- * same completed / failed / no-handler contract instead of re-deriving it.
20
- */
21
- async function runStepHandler(task, handler) {
22
- // Stamp the worker's pickup time so the engine can report queue-wait (startedAt − enqueuedAt).
23
- // This is the one place every transport funnels through, so timing comes for free everywhere.
24
- const base = { runId: task.runId, seq: task.seq, stepId: task.stepId, startedAt: Date.now() };
25
- if (!handler) {
26
- return {
27
- ...base,
28
- status: 'failed',
29
- error: { message: `no handler for ${task.name}`, retryable: false },
30
- };
31
- }
32
- const events = [];
33
- const withEvents = (result) => events.length > 0 ? { ...result, events } : result;
34
- try {
35
- const output = await handler(task.input, (0, step_logger_1.createStepLogger)(events, Date.now));
36
- return withEvents({ ...base, status: 'completed', output });
37
- }
38
- catch (err) {
39
- // Carry `code`/`retryable` off the thrown error if present, so the engine's durable retry can
40
- // honour a worker's "don't retry this" verdict (e.g. a declined card).
41
- const e = err;
42
- return withEvents({
43
- ...base,
44
- status: 'failed',
45
- error: {
46
- message: err instanceof Error ? err.message : String(err),
47
- ...(typeof e?.code === 'string' ? { code: e.code } : {}),
48
- ...(typeof e?.retryable === 'boolean' ? { retryable: e.retryable } : {}),
49
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8BAAgB,EAAC,MAAM,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;QAC7E,OAAO,UAAU,CAAC,EAAE,GAAG,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,CAAC,CAAC;IAC9D,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,8FAA8F;QAC9F,uEAAuE;QACvE,MAAM,CAAC,GAAG,GAA+D,CAAC;QAC1E,OAAO,UAAU,CAAC;YAChB,GAAG,IAAI;YACP,MAAM,EAAE,QAAQ;YAChB,KAAK,EAAE;gBACL,OAAO,EAAE,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC;gBACzD,GAAG,CAAC,OAAO,CAAC,EAAE,IAAI,KAAK,QAAQ,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;gBACxD,GAAG,CAAC,OAAO,CAAC,EAAE,SAAS,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,CAAC,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;aACzE;SACF,CAAC,CAAC;IACL,CAAC;AACH,CAAC"}
package/dist/queue.d.ts DELETED
@@ -1,48 +0,0 @@
1
- /**
2
- * Flow control for remote steps. A queue caps how much work `ctx.call(step, input, { queue })`
3
- * admits at once — a concurrency limit and/or a fixed-window rate limit. When a call can't be
4
- * admitted it doesn't dispatch: the run re-suspends with a near-future wake time, and the timer
5
- * poller re-tries admission later — so flow control is durable (survives crashes) without holding
6
- * the run in memory.
7
- *
8
- * Accounting is per engine instance (the DBOS `workerConcurrency` tier): correct for the common
9
- * single-orchestrator deployment. Global, cross-instance limits would need a durable counter in the
10
- * store — a deliberate follow-up, not built here.
11
- */
12
- export interface QueueConfig {
13
- /** Queue name, referenced by `ctx.call(step, input, { queue: name })`. */
14
- name: string;
15
- /** Max steps in flight at once for this queue (this instance). Omit for unlimited. */
16
- concurrency?: number;
17
- /** Fixed-window rate limit: at most `limit` admissions per `periodMs`. Omit for unlimited. */
18
- rateLimit?: {
19
- limit: number;
20
- periodMs: number;
21
- };
22
- /** Delay (ms) before a concurrency-blocked call re-checks for a free slot. Default 1000. */
23
- retryMs?: number;
24
- }
25
- /** Admission decision: either admitted, or blocked until `retryAt` (epoch ms). */
26
- export type Admission = {
27
- ok: true;
28
- } | {
29
- ok: false;
30
- retryAt: number;
31
- };
32
- /** In-process admission controller for one {@link QueueConfig}. */
33
- export declare class QueueController {
34
- readonly config: QueueConfig;
35
- private readonly clock;
36
- private inFlight;
37
- private windowStart;
38
- private windowCount;
39
- constructor(config: QueueConfig, clock: () => number);
40
- /**
41
- * Try to admit one unit of work. On `ok`, the caller has taken a concurrency slot and must call
42
- * {@link release} when the step settles. On block, `retryAt` is when admission may next succeed.
43
- */
44
- tryAdmit(): Admission;
45
- /** Release a concurrency slot taken by a successful {@link tryAdmit}. */
46
- release(): void;
47
- }
48
- //# sourceMappingURL=queue.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"queue.d.ts","sourceRoot":"","sources":["../src/queue.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,MAAM,WAAW,WAAW;IAC1B,0EAA0E;IAC1E,IAAI,EAAE,MAAM,CAAC;IACb,sFAAsF;IACtF,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,8FAA8F;IAC9F,SAAS,CAAC,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC;IAChD,4FAA4F;IAC5F,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,kFAAkF;AAClF,MAAM,MAAM,SAAS,GAAG;IAAE,EAAE,EAAE,IAAI,CAAA;CAAE,GAAG;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AAEtE,mEAAmE;AACnE,qBAAa,eAAe;IAMxB,QAAQ,CAAC,MAAM,EAAE,WAAW;IAC5B,OAAO,CAAC,QAAQ,CAAC,KAAK;IANxB,OAAO,CAAC,QAAQ,CAAK;IACrB,OAAO,CAAC,WAAW,CAAK;IACxB,OAAO,CAAC,WAAW,CAAK;gBAGb,MAAM,EAAE,WAAW,EACX,KAAK,EAAE,MAAM,MAAM;IAGtC;;;OAGG;IACH,QAAQ,IAAI,SAAS;IAmBrB,yEAAyE;IACzE,OAAO,IAAI,IAAI;CAGhB"}
package/dist/queue.js DELETED
@@ -1,45 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.QueueController = void 0;
4
- /** In-process admission controller for one {@link QueueConfig}. */
5
- class QueueController {
6
- config;
7
- clock;
8
- inFlight = 0;
9
- windowStart = 0;
10
- windowCount = 0;
11
- constructor(config, clock) {
12
- this.config = config;
13
- this.clock = clock;
14
- }
15
- /**
16
- * Try to admit one unit of work. On `ok`, the caller has taken a concurrency slot and must call
17
- * {@link release} when the step settles. On block, `retryAt` is when admission may next succeed.
18
- */
19
- tryAdmit() {
20
- const now = this.clock();
21
- const rl = this.config.rateLimit;
22
- if (rl) {
23
- if (now - this.windowStart >= rl.periodMs) {
24
- this.windowStart = now;
25
- this.windowCount = 0;
26
- }
27
- if (this.windowCount >= rl.limit)
28
- return { ok: false, retryAt: this.windowStart + rl.periodMs };
29
- }
30
- if (this.config.concurrency != null && this.inFlight >= this.config.concurrency) {
31
- return { ok: false, retryAt: now + (this.config.retryMs ?? 1000) };
32
- }
33
- if (rl)
34
- this.windowCount += 1;
35
- this.inFlight += 1;
36
- return { ok: true };
37
- }
38
- /** Release a concurrency slot taken by a successful {@link tryAdmit}. */
39
- release() {
40
- if (this.inFlight > 0)
41
- this.inFlight -= 1;
42
- }
43
- }
44
- exports.QueueController = QueueController;
45
- //# sourceMappingURL=queue.js.map
package/dist/queue.js.map DELETED
@@ -1 +0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,EAAE,IAAI,EAAE,CAAC;IACtB,CAAC;IAED,yEAAyE;IACzE,OAAO;QACL,IAAI,IAAI,CAAC,QAAQ,GAAG,CAAC;YAAE,IAAI,CAAC,QAAQ,IAAI,CAAC,CAAC;IAC5C,CAAC;CACF;AArCD,0CAqCC"}
@@ -1,15 +0,0 @@
1
- import type { z } from 'zod';
2
- import type { RemoteStepDef, StepOptions } from './interfaces';
3
- export interface RemoteStepConfig<TInput, TOutput> extends StepOptions {
4
- name: string;
5
- /** Worker group expected to handle this step. Defaults to the `name` prefix before the first dot. */
6
- group?: string;
7
- input: z.ZodType<TInput>;
8
- output: z.ZodType<TOutput>;
9
- }
10
- /**
11
- * Defines a typed handle to a step that runs on a remote worker. Call it from a workflow with
12
- * `ctx.call(step, input)`; a worker registers a handler under the same `name`.
13
- */
14
- export declare function remoteStep<TInput, TOutput>(config: RemoteStepConfig<TInput, TOutput>): RemoteStepDef<TInput, TOutput>;
15
- //# sourceMappingURL=remote-step-factory.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"remote-step-factory.d.ts","sourceRoot":"","sources":["../src/remote-step-factory.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,KAAK,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE/D,MAAM,WAAW,gBAAgB,CAAC,MAAM,EAAE,OAAO,CAAE,SAAQ,WAAW;IACpE,IAAI,EAAE,MAAM,CAAC;IACb,qGAAqG;IACrG,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;IACzB,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;CAC5B;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,MAAM,EAAE,OAAO,EACxC,MAAM,EAAE,gBAAgB,CAAC,MAAM,EAAE,OAAO,CAAC,GACxC,aAAa,CAAC,MAAM,EAAE,OAAO,CAAC,CAMhC"}
@@ -1,15 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.remoteStep = remoteStep;
4
- /**
5
- * Defines a typed handle to a step that runs on a remote worker. Call it from a workflow with
6
- * `ctx.call(step, input)`; a worker registers a handler under the same `name`.
7
- */
8
- function remoteStep(config) {
9
- return {
10
- ...config,
11
- group: config.group ?? config.name.split('.')[0] ?? config.name,
12
- __remote: true,
13
- };
14
- }
15
- //# sourceMappingURL=remote-step-factory.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"remote-step-factory.js","sourceRoot":"","sources":["../src/remote-step-factory.ts"],"names":[],"mappings":";;AAeA,gCAQC;AAZD;;;GAGG;AACH,SAAgB,UAAU,CACxB,MAAyC;IAEzC,OAAO;QACL,GAAG,MAAM;QACT,KAAK,EAAE,MAAM,CAAC,KAAK,IAAI,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,MAAM,CAAC,IAAI;QAC/D,QAAQ,EAAE,IAAI;KACf,CAAC;AACJ,CAAC"}
@@ -1,24 +0,0 @@
1
- import type { HistoryEvent, Transport, WorkflowDecision, WorkflowExecutor, WorkflowRun } from './interfaces';
2
- /**
3
- * A {@link WorkflowExecutor} backed by a {@link Transport}: it advances a remote workflow by
4
- * dispatching a {@link WorkflowTask} over the broker and awaiting the matching {@link WorkflowDecision}
5
- * (correlated by `taskId`). Pass one to `engine.registerRemote(name, version, { group, executor })` so
6
- * a workflow authored in another SDK (e.g. the Python `durable-worker`) is driven over Redis/BullMQ.
7
- *
8
- * Recovery-safe: if the engine crashes awaiting a decision, the re-drive dispatches a fresh task with
9
- * the same history — the worker's replay is deterministic, so it returns the same decision; a late
10
- * decision for the old `taskId` simply finds no waiter and is dropped.
11
- */
12
- export declare class RemoteWorkflowExecutor implements WorkflowExecutor {
13
- private readonly transport;
14
- private readonly group;
15
- private readonly opts;
16
- private readonly pending;
17
- private subscribed;
18
- constructor(transport: Transport, group: string, opts?: {
19
- timeoutMs?: number;
20
- });
21
- private ensureSubscribed;
22
- advance(run: WorkflowRun, history: HistoryEvent[]): Promise<WorkflowDecision>;
23
- }
24
- //# sourceMappingURL=remote-workflow-executor.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"remote-workflow-executor.d.ts","sourceRoot":"","sources":["../src/remote-workflow-executor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,YAAY,EACZ,SAAS,EACT,gBAAgB,EAChB,gBAAgB,EAChB,WAAW,EAEZ,MAAM,cAAc,CAAC;AAItB;;;;;;;;;GASG;AACH,qBAAa,sBAAuB,YAAW,gBAAgB;IAK3D,OAAO,CAAC,QAAQ,CAAC,SAAS;IAC1B,OAAO,CAAC,QAAQ,CAAC,KAAK;IACtB,OAAO,CAAC,QAAQ,CAAC,IAAI;IANvB,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA2D;IACnF,OAAO,CAAC,UAAU,CAAS;gBAGR,SAAS,EAAE,SAAS,EACpB,KAAK,EAAE,MAAM,EACb,IAAI,GAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAO;IAGpD,OAAO,CAAC,gBAAgB;IAelB,OAAO,CAAC,GAAG,EAAE,WAAW,EAAE,OAAO,EAAE,YAAY,EAAE,GAAG,OAAO,CAAC,gBAAgB,CAAC;CA8BpF"}
@@ -1,73 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.RemoteWorkflowExecutor = void 0;
4
- let taskCounter = 0;
5
- /**
6
- * A {@link WorkflowExecutor} backed by a {@link Transport}: it advances a remote workflow by
7
- * dispatching a {@link WorkflowTask} over the broker and awaiting the matching {@link WorkflowDecision}
8
- * (correlated by `taskId`). Pass one to `engine.registerRemote(name, version, { group, executor })` so
9
- * a workflow authored in another SDK (e.g. the Python `durable-worker`) is driven over Redis/BullMQ.
10
- *
11
- * Recovery-safe: if the engine crashes awaiting a decision, the re-drive dispatches a fresh task with
12
- * the same history — the worker's replay is deterministic, so it returns the same decision; a late
13
- * decision for the old `taskId` simply finds no waiter and is dropped.
14
- */
15
- class RemoteWorkflowExecutor {
16
- transport;
17
- group;
18
- opts;
19
- pending = new Map();
20
- subscribed = false;
21
- constructor(transport, group, opts = {}) {
22
- this.transport = transport;
23
- this.group = group;
24
- this.opts = opts;
25
- }
26
- ensureSubscribed() {
27
- if (this.subscribed)
28
- return;
29
- if (!this.transport.onDecision) {
30
- throw new Error('transport does not support workflow decisions (onDecision)');
31
- }
32
- this.subscribed = true;
33
- this.transport.onDecision(async (decision) => {
34
- const resolve = this.pending.get(decision.taskId);
35
- if (resolve) {
36
- this.pending.delete(decision.taskId);
37
- resolve(decision);
38
- }
39
- });
40
- }
41
- async advance(run, history) {
42
- if (!this.transport.dispatchWorkflowTask) {
43
- throw new Error('transport does not support workflow tasks (dispatchWorkflowTask)');
44
- }
45
- this.ensureSubscribed();
46
- taskCounter += 1;
47
- const taskId = `${run.id}:wf:${taskCounter}`;
48
- const task = {
49
- taskId,
50
- runId: run.id,
51
- workflow: run.workflow,
52
- workflowVersion: run.workflowVersion,
53
- input: run.input,
54
- history,
55
- group: this.group,
56
- attempt: 1,
57
- };
58
- const decision = new Promise((resolve, reject) => {
59
- this.pending.set(taskId, resolve);
60
- if (this.opts.timeoutMs) {
61
- const timer = setTimeout(() => {
62
- this.pending.delete(taskId);
63
- reject(new Error(`workflow task ${taskId} timed out after ${this.opts.timeoutMs}ms`));
64
- }, this.opts.timeoutMs);
65
- timer.unref?.();
66
- }
67
- });
68
- await this.transport.dispatchWorkflowTask(task);
69
- return decision;
70
- }
71
- }
72
- exports.RemoteWorkflowExecutor = RemoteWorkflowExecutor;
73
- //# sourceMappingURL=remote-workflow-executor.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"remote-workflow-executor.js","sourceRoot":"","sources":["../src/remote-workflow-executor.ts"],"names":[],"mappings":";;;AASA,IAAI,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B,MAAM;YACN,KAAK,EAAE,GAAG,CAAC,EAAE;YACb,QAAQ,EAAE,GAAG,CAAC,QAAQ;YACtB,eAAe,EAAE,GAAG,CAAC,eAAe;YACpC,KAAK,EAAE,GAAG,CAAC,KAAK;YAChB,OAAO;YACP,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,OAAO,EAAE,CAAC;SACX,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,OAAO,CAAmB,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;YACjE,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;YAClC,IAAI,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,CAAC;gBACxB,MAAM,KAAK,GAAG,UAAU,CAAC,GAAG,EAAE;oBAC5B,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;oBAC5B,MAAM,CAAC,IAAI,KAAK,CAAC,iBAAiB,MAAM,oBAAoB,IAAI,CAAC,IAAI,CAAC,SAAS,IAAI,CAAC,CAAC,CAAC;gBACxF,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;gBACvB,KAAgC,CAAC,KAAK,EAAE,EAAE,CAAC;YAC9C,CAAC;QACH,CAAC,CAAC,CAAC;QACH,MAAM,IAAI,CAAC,SAAS,CAAC,oBAAoB,CAAC,IAAI,CAAC,CAAC;QAChD,OAAO,QAAQ,CAAC;IAClB,CAAC;CACF;AAvDD,wDAuDC"}
@@ -1,42 +0,0 @@
1
- import type { WorkflowEngine } from './engine';
2
- export interface ScheduledWorkflow {
3
- /** Stable key identifying this schedule — part of the deterministic run id. */
4
- key: string;
5
- workflow: string;
6
- input?: unknown;
7
- /** Start one run every `everyMs`. Mutually exclusive with `cron`. */
8
- everyMs?: number;
9
- /**
10
- * A cron expression (5 fields `m h dom mon dow`, or 6 with leading seconds) evaluated in
11
- * {@link ScheduledWorkflow.timezone}. Mutually exclusive with `everyMs`. Needs the optional peer
12
- * dependency `cron-parser`.
13
- */
14
- cron?: string;
15
- /** IANA timezone the `cron` fires in (e.g. `America/Sao_Paulo`). Defaults to UTC. */
16
- timezone?: string;
17
- /** Temporarily stop firing this schedule (kept registered). Defaults to false. */
18
- paused?: boolean;
19
- /**
20
- * What to do when the previous window's run hasn't finished yet (fixed-interval schedules only):
21
- * `'allow'` (default) starts the new window anyway; `'skip'` skips it while the prior run is still
22
- * `running`/`suspended`, so a slow run can't pile up overlapping executions.
23
- */
24
- overlap?: 'allow' | 'skip';
25
- }
26
- /** Deterministic run id for a fixed-interval schedule's current time window. */
27
- export declare function scheduledRunId(key: string, everyMs: number, nowMs: number): string;
28
- /**
29
- * Epoch ms of the most recent cron fire at or before `nowMs`, evaluated in `timezone` (default UTC).
30
- * This is the deterministic "bucket" a cron run is keyed on, so polling repeatedly within an
31
- * interval resolves to the same fire time — and thus the same idempotent run id.
32
- */
33
- export declare function prevCronFireMs(expr: string, nowMs: number, timezone?: string): number;
34
- /**
35
- * Start each schedule's current-window run. The run id is the time bucket (a fixed-interval index,
36
- * or the cron fire time) and `engine.start` is idempotent, so firing this on an interval — or
37
- * racing two instances on the same tick — starts **each window exactly once**. Wire it to a
38
- * `setInterval`, the durable timer poller, or `@nestjs/schedule`. Returns the run ids for the
39
- * current windows.
40
- */
41
- export declare function runSchedules(engine: Pick<WorkflowEngine, 'start' | 'getRun'>, schedules: readonly ScheduledWorkflow[], nowMs: number): Promise<string[]>;
42
- //# sourceMappingURL=scheduler.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"scheduler.d.ts","sourceRoot":"","sources":["../src/scheduler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAE/C,MAAM,WAAW,iBAAiB;IAChC,+EAA+E;IAC/E,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,qEAAqE;IACrE,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,qFAAqF;IACrF,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,kFAAkF;IAClF,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CAC5B;AAED,gFAAgF;AAChF,wBAAgB,cAAc,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,CAElF;AAiBD;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,SAAQ,GAAG,MAAM,CAKpF;AASD;;;;;;GAMG;AACH,wBAAsB,YAAY,CAChC,MAAM,EAAE,IAAI,CAAC,cAAc,EAAE,OAAO,GAAG,QAAQ,CAAC,EAChD,SAAS,EAAE,SAAS,iBAAiB,EAAE,EACvC,KAAK,EAAE,MAAM,GACZ,OAAO,CAAC,MAAM,EAAE,CAAC,CAkBnB"}
package/dist/scheduler.js DELETED
@@ -1,70 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.scheduledRunId = scheduledRunId;
4
- exports.prevCronFireMs = prevCronFireMs;
5
- exports.runSchedules = runSchedules;
6
- /** Deterministic run id for a fixed-interval schedule's current time window. */
7
- function scheduledRunId(key, everyMs, nowMs) {
8
- return `sched:${key}:${Math.floor(nowMs / everyMs)}`;
9
- }
10
- let cronParser;
11
- function loadCronParser() {
12
- if (cronParser)
13
- return cronParser;
14
- try {
15
- // Lazy + optional: core stays dependency-free; only users who schedule by cron need this.
16
- cronParser = require('cron-parser');
17
- }
18
- catch {
19
- throw new Error('cron schedules need the optional peer dependency "cron-parser" — install it (e.g. `npm i cron-parser`).');
20
- }
21
- return cronParser;
22
- }
23
- /**
24
- * Epoch ms of the most recent cron fire at or before `nowMs`, evaluated in `timezone` (default UTC).
25
- * This is the deterministic "bucket" a cron run is keyed on, so polling repeatedly within an
26
- * interval resolves to the same fire time — and thus the same idempotent run id.
27
- */
28
- function prevCronFireMs(expr, nowMs, timezone = 'UTC') {
29
- const parser = loadCronParser();
30
- // `+1` makes a fire landing exactly on `nowMs` count as "at or before now", not the prior one.
31
- const it = parser.parseExpression(expr, { currentDate: new Date(nowMs + 1), tz: timezone });
32
- return it.prev().toDate().getTime();
33
- }
34
- /** The deterministic, idempotent run id for a schedule at `nowMs` — its current fire window. */
35
- function scheduleRunIdAt(s, nowMs) {
36
- if (s.cron != null)
37
- return `sched:${s.key}:${prevCronFireMs(s.cron, nowMs, s.timezone)}`;
38
- if (s.everyMs != null)
39
- return scheduledRunId(s.key, s.everyMs, nowMs);
40
- throw new Error(`schedule "${s.key}" needs either "everyMs" or "cron"`);
41
- }
42
- /**
43
- * Start each schedule's current-window run. The run id is the time bucket (a fixed-interval index,
44
- * or the cron fire time) and `engine.start` is idempotent, so firing this on an interval — or
45
- * racing two instances on the same tick — starts **each window exactly once**. Wire it to a
46
- * `setInterval`, the durable timer poller, or `@nestjs/schedule`. Returns the run ids for the
47
- * current windows.
48
- */
49
- async function runSchedules(engine, schedules, nowMs) {
50
- const ids = [];
51
- for (const s of schedules) {
52
- if (s.paused)
53
- continue;
54
- // overlap:'skip' (fixed-interval): don't start this window while the previous window's run is
55
- // still in-flight, so a slow run can't pile up. Interval-only — cron windows aren't adjacent ids.
56
- if (s.overlap === 'skip' && s.everyMs) {
57
- const prevBucket = Math.floor(nowMs / s.everyMs) - 1;
58
- if (prevBucket >= 0) {
59
- const prev = await engine.getRun(`sched:${s.key}:${prevBucket}`);
60
- if (prev && (prev.status === 'running' || prev.status === 'suspended'))
61
- continue;
62
- }
63
- }
64
- const runId = scheduleRunIdAt(s, nowMs);
65
- await engine.start(s.workflow, s.input, runId);
66
- ids.push(runId);
67
- }
68
- return ids;
69
- }
70
- //# sourceMappingURL=scheduler.js.map