repositories
/
poolifier.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
fix: ensure worker removal impact is propated to worker choice strategy
[poolifier.git]
/
src
/
pools
/
selection-strategies
/
selection-strategies-types.ts
diff --git
a/src/pools/selection-strategies/selection-strategies-types.ts
b/src/pools/selection-strategies/selection-strategies-types.ts
index a05fd9b784c9da682cd0e270f09b81ce41325d70..c098768533fcced20246044d5411ad1ebb7bb76c 100644
(file)
--- a/
src/pools/selection-strategies/selection-strategies-types.ts
+++ b/
src/pools/selection-strategies/selection-strategies-types.ts
@@
-56,4
+56,10
@@
export interface IWorkerChoiceStrategy {
* Chooses a worker in the pool and returns its key.
*/
choose: () => number
+ /**
+ * Removes a worker reference from strategy internals.
+ *
+ * @param workerKey - The worker key.
+ */
+ remove: (workerKey: number) => boolean
}