test: test for wait node readiness in dynamic pool
[poolifier.git] / src / pools / selection-strategies / worker-choice-strategy-context.ts
index d6a6e26d27e87fbb263a9ef5b61e5c1745b60950..14e734fd6a50bd40647ebc9af012dc77d24654ac 100644 (file)
@@ -170,7 +170,7 @@ export class WorkerChoiceStrategyContext<
       this.workerChoiceStrategy
     ) as IWorkerChoiceStrategy
     if (!workerChoiceStrategy.hasPoolWorkerNodesReady()) {
-      // wait for a worker node to be ready without blocking the event loop
+      return this.execute()
     }
     return this.executeStrategy(workerChoiceStrategy)
   }