X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FDynamicClusterPool.html;h=1767983b04add9aa7d5360d287e04c72716bb93a;hb=601deb7292c99dfe7b6ad43935759933f32adca1;hp=5bbe0ff4edc5dc2d845e531f55e0390415945100;hpb=b7ca12ae3bfb54a42c0e9879067fc3a976685bb7;p=poolifier.git diff --git a/docs/classes/DynamicClusterPool.html b/docs/classes/DynamicClusterPool.html index 5bbe0ff4..1767983b 100644 --- a/docs/classes/DynamicClusterPool.html +++ b/docs/classes/DynamicClusterPool.html @@ -1,13 +1,13 @@ -DynamicClusterPool | poolifier - v2.6.32
+DynamicClusterPool | poolifier - v3.0.3
-
+
  • The search index is not available
  • poolifier - v3.0.3 +
    @@ -45,19 +45,19 @@ When the maximum number of workers is reached and workers are busy, an event is
    • DynamicClusterPool
    +
  • Defined in src/pools/cluster/dynamic.ts:16
  • - +

    Constructors

    - +
    +
  • Defined in src/pools/cluster/dynamic.ts:28
  • Properties

    - -
    emitter?: PoolEmitter
    -

    Emitter on which events can be listened to.

    + +
    emitter?: EventEmitterAsyncResource
    +

    Event emitter integrated with async resource on which events can be listened to. +The async tracking tooling identifier is poolifier:<PoolType>-<WorkerType>-pool.

    Events that can currently be listened to:

    • 'ready': Emitted when the number of workers created in the pool has reached the minimum size expected and are ready.
    • -
    • 'busy': Emitted when the number of workers created in the pool has reached the maximum size expected and are executing at least one task.
    • +
    • 'busy': Emitted when the number of workers created in the pool has reached the maximum size expected and are executing concurrently their tasks quota.
    • 'full': Emitted when the pool is dynamic and the number of workers created has reached the maximum size expected.
    • -
    • 'destroy': Emitted when the pool is destroyed.
    • +
    • 'destroy': Emitted when the pool is destroyed.
    • 'error': Emitted when an uncaught error occurs.
    • 'taskError': Emitted when an error occurs while executing a task.
    • 'backPressure': Emitted when all worker nodes have back pressure (i.e. their tasks queue is full: queue size >= maximum queue size).
    • @@ -171,7 +179,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:74
  • filePath: string
    @@ -180,7 +188,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:129
  • max: number
    @@ -189,7 +197,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/cluster/dynamic.ts:30
  • numberOfWorkers: number
    @@ -198,7 +206,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:128
  • @@ -207,11 +215,11 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/cluster/fixed.ts:47
  • promiseResponseMap: Map<string, PromiseResponseWrapper<Response>> = ...
    -

    The task execution response promise map.

    +

    The task execution response promise map:

    • key: The message id of each submitted task.
    • value: An object that contains the worker, the execution response promise resolve and reject callbacks.
    • @@ -221,7 +229,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:88
  • workerChoiceStrategyContext: WorkerChoiceStrategyContext<Worker, Data, Response>
    @@ -230,7 +238,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:94
  • workerNodes: IWorkerNode<Worker, Data>[] = []
    @@ -239,7 +247,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:71
  • Accessors

    @@ -254,7 +262,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/cluster/dynamic.ts:44
    • @@ -267,7 +275,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:659
    • @@ -279,7 +287,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:272
    • @@ -291,7 +299,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:485
    • @@ -303,7 +311,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:478
    • @@ -315,7 +323,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:430
    • @@ -328,7 +336,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/cluster/dynamic.ts:39
    • @@ -341,7 +349,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:447
    • @@ -353,9 +361,40 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/cluster/fixed.ts:135
  • Methods

    +
    + +
    +
  • Defined in src/pools/abstract-pool.ts:1041
  • +
  • Defined in src/pools/abstract-pool.ts:1354
  • -
    - -
    +
  • Defined in src/pools/abstract-pool.ts:1011
  • +
  • Defined in src/pools/abstract-pool.ts:1258
  • +
  • Defined in src/pools/abstract-pool.ts:1214
  • +
  • Defined in src/pools/cluster/fixed.ts:125
  • +
    + +
      + +
    • +

      Deregisters a listener callback on the worker given its worker node key.

      +
      +
      +

      Type Parameters

      +
        +
      • +

        Message

      +
      +

      Parameters

      +
        +
      • +
        workerNodeKey: number
        +

        The worker node key.

        +
        +
      • +
      • +
        listener: ((message) => void)
        +

        The message listener callback.

        +
        +
        +
          +
        • +
            +
          • (message): void
          • +
          • +
            +

            Parameters

            +
            +

            Returns void

      +

      Returns void

      +
    +
  • Defined in src/pools/abstract-pool.ts:948
  • +
  • Defined in src/pools/cluster/fixed.ts:63
  • +
  • Defined in src/pools/abstract-pool.ts:563
  • +
  • Defined in src/pools/abstract-pool.ts:878
  • +
    + +
    +
  • Defined in src/pools/abstract-pool.ts:1690
    • - +
    • Gets the worker information given its worker node key.

      @@ -601,12 +679,33 @@ Can be overridden.

      The worker node key.

    -

    Returns undefined | WorkerInfo

    The worker information.

    +

    Returns WorkerInfo

    The worker information.

    +
  • Defined in src/pools/abstract-pool.ts:1602
  • +
    + +
      + +
    • +

      Whether the specified task function exists in this pool.

      +
      +
      +

      Parameters

      +
        +
      • +
        name: string
        +

        The name of the task function.

        +
        +
      +

      Returns boolean

      true if the task function exists, false otherwise.

      + +
    +
  • Defined in src/pools/abstract-pool.ts:1648
  • +
  • Defined in src/pools/abstract-pool.ts:675
  • -
    - +
  • Defined in src/pools/cluster/fixed.ts:58
  • +
    +
    +
    + +
      + +
    • +

      Registers once a listener callback on the worker given its worker node key.

      +
      +
      +

      Type Parameters

      +
        +
      • +

        Message

      +
      +

      Parameters

      +
        +
      • +
        workerNodeKey: number
        +

        The worker node key.

        +
        +
      • +
      • +
        listener: ((message) => void)
        +

        The message listener callback.

        +
        +
        +
          +
        • +
            +
          • (message): void
          • +
          • +
            +

            Parameters

            +
            +

            Returns void

      +

      Returns void

      +
    +
  • Defined in src/pools/cluster/fixed.ts:109
  • +
  • Defined in src/pools/cluster/fixed.ts:101
  • +
    + +
      + +
    • +

      Removes a task function from this pool.

      +
      +
      +

      Parameters

      +
        +
      • +
        name: string
        +

        The name of the task function.

        +
        +
      +

      Returns Promise<boolean>

      true if the task function was removed, false otherwise.

      + +
      - +
    • Parameters

      • -
        workerNodeKey: number
      • -
      • -
        workerId: number
      +
      workerNodeKey: number

    Returns Promise<void>

    +
  • Defined in src/pools/abstract-pool.ts:959
  • +
  • Defined in src/pools/cluster/fixed.ts:94
  • +
  • Defined in src/pools/cluster/fixed.ts:83
  • +
    + +
    +
  • Defined in src/pools/abstract-pool.ts:577
  • +
  • Defined in src/pools/abstract-pool.ts:530
  • +
  • Defined in src/pools/abstract-pool.ts:549
  • -
    - -
    +
    + +
    +
    + + +

    Returns void

    +
  • Defined in src/pools/abstract-pool.ts:1516
  • +
    -

    Generated using TypeDoc

    -
    \ No newline at end of file +

    Generated using TypeDoc

    +
    \ No newline at end of file