X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FWorkerChoiceStrategyContext.html;h=eefcff60d5037d53bd528155a9e5849e27f7f833;hb=a941ca40d6503650aa3bb05f1d4f5946e041f16b;hp=582b22514d5f828d875f20647b7bd7861728c140;hpb=dbf662afd2c11c4d18c4e648f90d392528a715f8;p=poolifier.git diff --git a/docs/classes/WorkerChoiceStrategyContext.html b/docs/classes/WorkerChoiceStrategyContext.html index 582b2251..eefcff60 100644 --- a/docs/classes/WorkerChoiceStrategyContext.html +++ b/docs/classes/WorkerChoiceStrategyContext.html @@ -1,316 +1,39 @@ -WorkerChoiceStrategyContext | poolifier - v2.7.0
-
- -
-
-
-
- -

Class WorkerChoiceStrategyContext<Worker, Data, Response>

-
-

The worker choice strategy context.

-
-
-
-

Type Parameters

-
    -
  • -

    Worker extends IWorker

    -

    Type of worker.

    -
    -
  • -
  • -

    Data = unknown

    -

    Type of data sent to the worker. This can only be structured-cloneable data.

    -
    -
  • -
  • -

    Response = unknown

    -

    Type of execution response. This can only be structured-cloneable data.

    -
    -
-
-

Hierarchy

-
    -
  • WorkerChoiceStrategyContext
-
-
-
- -
-
-

Constructors

-
-
-

Properties

-
opts -retriesCount +WorkerChoiceStrategyContext | poolifier - v3.1.2

Class WorkerChoiceStrategyContext<Worker, Data, Response>

The worker choice strategy context.

+

Type Parameters

  • Worker extends IWorker

    Type of worker.

    +
  • Data = unknown

    Type of data sent to the worker. This can only be structured-cloneable data.

    +
  • Response = unknown

    Type of execution response. This can only be structured-cloneable data.

    +
-
-

Constructors

-
- -
    - -
  • -

    Worker choice strategy context constructor.

    -
    -
    -

    Type Parameters

    -
      -
    • -

      Worker extends IWorker

    • -
    • -

      Data = unknown

    • -
    • -

      Response = unknown

    -
    -

    Parameters

    -
      -
    • -
      pool: IPool<Worker, Data, Response>
      -

      The pool instance.

      -
      -
    • -
    • -
      workerChoiceStrategy: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN" = WorkerChoiceStrategies.ROUND_ROBIN
      -

      The worker choice strategy.

      -
      -
    • -
    • -
      opts: WorkerChoiceStrategyOptions = DEFAULT_WORKER_CHOICE_STRATEGY_OPTIONS
      -

      The worker choice strategy options.

      -
      -
    -

    Returns WorkerChoiceStrategyContext<Worker, Data, Response>

    -
-
-

Properties

-
- -
opts: WorkerChoiceStrategyOptions = DEFAULT_WORKER_CHOICE_STRATEGY_OPTIONS
-

The worker choice strategy options.

-
-
-
- -
retriesCount: number = 0
-

The number of times the worker choice strategy in the context has been retried.

-
-
-
- -
workerChoiceStrategies: Map<"ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN", IWorkerChoiceStrategy>
-
- -
workerChoiceStrategy: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN" = WorkerChoiceStrategies.ROUND_ROBIN
-

The worker choice strategy.

-
-
-
-

Methods

-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
    - -
  • -

    Sets the worker choice strategy to use in the context.

    -
    -
    -

    Parameters

    -
      -
    • -
      workerChoiceStrategy: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN"
      -

      The worker choice strategy to set.

      -
      -
    -

    Returns void

    -
-
- -
-
-
-

Generated using TypeDoc

-
\ No newline at end of file +

Constructors

Properties

opts: WorkerChoiceStrategyOptions = DEFAULT_WORKER_CHOICE_STRATEGY_OPTIONS

The worker choice strategy options.

+
workerChoiceStrategies: Map<"ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN", IWorkerChoiceStrategy>
workerChoiceStrategy: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN" = WorkerChoiceStrategies.ROUND_ROBIN

The worker choice strategy.

+

Methods

  • Sets the worker choice strategy to use in the context.

    +

    Parameters

    • workerChoiceStrategy: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN"

      The worker choice strategy to set.

      +

    Returns void

Generated using TypeDoc

\ No newline at end of file