repositories
/
poolifier.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
chore: v2.6.40
[poolifier.git]
/
src
/
pools
/
selection-strategies
/
weighted-round-robin-worker-choice-strategy.ts
diff --git
a/src/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.ts
b/src/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.ts
index c87081a6161c82ab612d5aca2b37a49e6b1089b0..b023bfb0cd258641354c81c465c20fa9a3b0b309 100644
(file)
--- a/
src/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.ts
+++ b/
src/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.ts
@@
-81,6
+81,9
@@
export class WeightedRoundRobinWorkerChoiceStrategy<
}
if (this.nextWorkerNodeKey === workerNodeKey) {
this.workerVirtualTaskRunTime = 0
}
if (this.nextWorkerNodeKey === workerNodeKey) {
this.workerVirtualTaskRunTime = 0
+ if (this.nextWorkerNodeKey > this.pool.workerNodes.length - 1) {
+ this.nextWorkerNodeKey = this.pool.workerNodes.length - 1
+ }
}
if (
this.previousWorkerNodeKey === workerNodeKey &&
}
if (
this.previousWorkerNodeKey === workerNodeKey &&