@orkestrel/worker 0.0.15 → 0.0.17

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.
@@ -216,7 +216,8 @@ export declare interface WorkerInterface<TInput, TResult> {
216
216
  * @remarks
217
217
  * - `handler` — runs each job against an acquired pool resource; rejecting triggers a
218
218
  * retry while attempts remain (delegated to the underlying queue).
219
- * - `pool` — the {@link PoolOptions} forwarded to the owned pool for validation. When both
219
+ * - `pool` — the resource options from {@link PoolOptions}, refusing values that can carry
220
+ * `capacity`, forwarded to the owned pool for validation. When both
220
221
  * `max` and `min` are absent, `max` defaults to `concurrency`. With `min`, the pool defaults
221
222
  * `max` to `min`, requires equality and `restarts`, and starts warming at construction.
222
223
  * The floor can exceed queue concurrency; `watch` observes each resource's loss.
@@ -236,7 +237,9 @@ declare interface WorkerOptions_2<TInput, TResource, TResult> {
236
237
  /** Holds the emitter's listener-error handler; a listener throw routes here, not to a domain event. */
237
238
  readonly error?: EmitterErrorHandler;
238
239
  readonly handler: WorkerHandler<TInput, TResource, TResult>;
239
- readonly pool: PoolOptions<TResource>;
240
+ readonly pool: Omit<PoolOptions<TResource>, 'capacity'> & {
241
+ readonly capacity?: never;
242
+ };
240
243
  readonly concurrency?: number;
241
244
  readonly retries?: number;
242
245
  /** Holds integer milliseconds in `0..2_147_483_647`; `0` disables the per-attempt deadline. */
@@ -216,7 +216,8 @@ export declare interface WorkerInterface<TInput, TResult> {
216
216
  * @remarks
217
217
  * - `handler` — runs each job against an acquired pool resource; rejecting triggers a
218
218
  * retry while attempts remain (delegated to the underlying queue).
219
- * - `pool` — the {@link PoolOptions} forwarded to the owned pool for validation. When both
219
+ * - `pool` — the resource options from {@link PoolOptions}, refusing values that can carry
220
+ * `capacity`, forwarded to the owned pool for validation. When both
220
221
  * `max` and `min` are absent, `max` defaults to `concurrency`. With `min`, the pool defaults
221
222
  * `max` to `min`, requires equality and `restarts`, and starts warming at construction.
222
223
  * The floor can exceed queue concurrency; `watch` observes each resource's loss.
@@ -236,7 +237,9 @@ declare interface WorkerOptions_2<TInput, TResource, TResult> {
236
237
  /** Holds the emitter's listener-error handler; a listener throw routes here, not to a domain event. */
237
238
  readonly error?: EmitterErrorHandler;
238
239
  readonly handler: WorkerHandler<TInput, TResource, TResult>;
239
- readonly pool: PoolOptions<TResource>;
240
+ readonly pool: Omit<PoolOptions<TResource>, 'capacity'> & {
241
+ readonly capacity?: never;
242
+ };
240
243
  readonly concurrency?: number;
241
244
  readonly retries?: number;
242
245
  /** Holds integer milliseconds in `0..2_147_483_647`; `0` disables the per-attempt deadline. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@orkestrel/worker",
3
- "version": "0.0.15",
3
+ "version": "0.0.17",
4
4
  "description": "A typed, resource-backed job worker for the @orkestrel line — a Queue paired with a Pool over an execution seam, plus a node:worker_threads server surface for CPU-parallel jobs. Part of the @orkestrel line.",
5
5
  "keywords": [
6
6
  "async",
@@ -84,22 +84,22 @@
84
84
  },
85
85
  "dependencies": {
86
86
  "@orkestrel/contract": "^0.0.19",
87
- "@orkestrel/database": "^0.0.17",
88
- "@orkestrel/emitter": "^0.0.11",
89
- "@orkestrel/pool": "^0.0.14",
90
- "@orkestrel/queue": "^0.0.16"
87
+ "@orkestrel/database": "^0.0.18",
88
+ "@orkestrel/emitter": "^0.0.12",
89
+ "@orkestrel/pool": "^0.0.17",
90
+ "@orkestrel/queue": "^0.0.17"
91
91
  },
92
92
  "devDependencies": {
93
- "@microsoft/api-extractor": "^7.59.3",
93
+ "@microsoft/api-extractor": "^7.59.4",
94
94
  "@orkestrel/guide": "^0.0.24",
95
- "@orkestrel/probe": "^0.0.19",
96
- "@orkestrel/scaffold": "^0.0.90",
97
- "@orkestrel/test": "^0.0.24",
95
+ "@orkestrel/probe": "^0.0.22",
96
+ "@orkestrel/scaffold": "^0.0.96",
97
+ "@orkestrel/test": "^0.0.25",
98
98
  "@types/node": "^26.6.4",
99
- "oxfmt": "^0.71.0",
100
- "oxlint": "^1.86.0",
99
+ "oxfmt": "^0.72.0",
100
+ "oxlint": "^1.87.0",
101
101
  "typescript": "^6.0.3",
102
- "vite": "^8.3.2",
102
+ "vite": "^8.3.3",
103
103
  "vitest": "^4.1.11"
104
104
  },
105
105
  "engines": {