fix: ensure worker choice strategy internals are reset
[poolifier.git] / src / pools / selection-strategies / abstract-worker-choice-strategy.ts
index cc38d196941e4611af2235a84899cd82ab55c9f0..d017122113cce8c5ef62a8f0812522fba1a354ad 100644 (file)
@@ -93,6 +93,11 @@ export abstract class AbstractWorkerChoiceStrategy<
     }
   }
 
+  protected resetWorkerNodeKeyProperties (): void {
+    this.nextWorkerNodeKey = 0
+    this.previousWorkerNodeKey = 0
+  }
+
   /** @inheritDoc */
   public abstract reset (): boolean