From 95ec6006ca39aef0102c82ca42e104a4e9b40b6b Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Sat, 15 Apr 2023 15:15:04 +0200 Subject: [PATCH] docs: refine worker choice strategy documentation MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- src/pools/pool.ts | 2 +- .../selection-strategies/worker-choice-strategy-context.ts | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/pools/pool.ts b/src/pools/pool.ts index 4115ab5b..f4a17915 100644 --- a/src/pools/pool.ts +++ b/src/pools/pool.ts @@ -84,7 +84,7 @@ export interface PoolOptions { /** * The worker choice strategy to use in this pool. * - * @defaultValue 'ROUND_ROBIN' + * @defaultValue WorkerChoiceStrategies.ROUND_ROBIN */ workerChoiceStrategy?: WorkerChoiceStrategy /** diff --git a/src/pools/selection-strategies/worker-choice-strategy-context.ts b/src/pools/selection-strategies/worker-choice-strategy-context.ts index 5e9f7de9..9a7bb81b 100644 --- a/src/pools/selection-strategies/worker-choice-strategy-context.ts +++ b/src/pools/selection-strategies/worker-choice-strategy-context.ts @@ -40,6 +40,9 @@ export class WorkerChoiceStrategyContext< */ public constructor ( pool: IPool, + /** + * @defaultValue WorkerChoiceStrategies.ROUND_ROBIN + */ private workerChoiceStrategy: WorkerChoiceStrategy = WorkerChoiceStrategies.ROUND_ROBIN, opts: WorkerChoiceStrategyOptions = DEFAULT_WORKER_CHOICE_STRATEGY_OPTIONS ) { -- 2.34.1