]> Piment Noir Git Repositories - poolifier.git/commit
fix(pool): reject task promises on unexpected worker exit (#3343)
authorJérôme Benoit <jerome.benoit@piment-noir.org>
Fri, 16 Oct 2026 17:36:35 +0000 (19:36 +0200)
committerGitHub <noreply@github.com>
Fri, 16 Oct 2026 17:36:35 +0000 (19:36 +0200)
commitaba7015b6994daf843b73bd8d49fdfdf0ebadadc
treee82a83ee59fad9d6c5879368ad72a85d4e47f0a3
parent6f5f7b3be989fc2cc99533dc404aae05f971d1c6
fix(pool): reject task promises on unexpected worker exit (#3343)

* fix(pool): reject task promises on unexpected worker exit

* fix(pool): finalize exited workers before settling tasks

* docs(api): scope worker response guarantees by transport

* fix(pool): preserve affinity and normalize worker failures

* fix(pool): settle exited worker tasks when replacement fails

* fix(pool): complete exit callbacks and thread termination

* fix(pool): preserve aborts during queue redistribution

* fix(pool): defer dequeue notifications until redistribution completes

* [autofix.ci] apply automated fixes

* fix(pool): redistribute tasks after worker reindexing

* fix(pool): isolate synchronous task send failures

* fix(pool): preserve detached queue recovery and cancellation

* docs(api): clarify worker failure guarantees

* fix(pool): defer dequeue notifications across worker removal

* fix(pool): preserve affinity while survivors initialize

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
12 files changed:
docs/api.md
src/pools/abstract-pool.ts
src/pools/worker-node.ts
src/pools/worker.ts
src/utility-types.ts
tests/pools/cluster/fixed.test.mjs
tests/pools/thread/fixed.test.mjs
tests/pools/worker-exit.test.mjs [new file with mode: 0644]
tests/pools/worker-node.test.mjs
tests/worker-files/cluster/crashWorker.cjs [new file with mode: 0644]
tests/worker-files/thread/bootstrapAffinityWorker.mjs [new file with mode: 0644]
tests/worker-files/thread/crashWorker.mjs [new file with mode: 0644]