X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FDynamicClusterPool.html;h=3c8b321fcf74e144f7d792f234d8c661977ec7ba;hb=49fb18fe8d6e6a35ceabe2bce83b26073871e3b0;hp=5bbe0ff4edc5dc2d845e531f55e0390415945100;hpb=c74b6981dbc78aa19a73c690eace221969bb997f;p=poolifier.git diff --git a/docs/classes/DynamicClusterPool.html b/docs/classes/DynamicClusterPool.html index 5bbe0ff4..3c8b321f 100644 --- a/docs/classes/DynamicClusterPool.html +++ b/docs/classes/DynamicClusterPool.html @@ -1,13 +1,13 @@ -DynamicClusterPool | poolifier - v2.6.32
+DynamicClusterPool | poolifier - v2.7.4
-
+
  • The search index is not available
  • poolifier - v2.7.4 +
    @@ -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?: __module | 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 +178,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:73
  • filePath: string
    @@ -180,7 +187,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:128
  • max: number
    @@ -189,7 +196,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 +205,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:127
  • @@ -207,11 +214,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 +228,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:82
  • workerChoiceStrategyContext: WorkerChoiceStrategyContext<Worker, Data, Response>
    @@ -230,7 +237,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:88
  • workerNodes: IWorkerNode<Worker, Data>[] = []
    @@ -239,7 +246,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:70
  • Accessors

    @@ -254,7 +261,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 +274,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:651
    • @@ -279,7 +286,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:271
    • @@ -291,7 +298,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:484
    • @@ -303,7 +310,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:477
    • @@ -315,7 +322,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:429
    • @@ -328,7 +335,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 +348,7 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/abstract-pool.ts:446
    • @@ -353,9 +360,40 @@ When the maximum number of workers is reached and workers are busy, an event is
    +
  • Defined in src/pools/cluster/fixed.ts:134
  • Methods

    +
    + +
    +
  • Defined in src/pools/abstract-pool.ts:1035
  • +
  • Defined in src/pools/abstract-pool.ts:1346
  • -
    - -
    +
  • Defined in src/pools/abstract-pool.ts:1005
  • +
  • Defined in src/pools/abstract-pool.ts:1252
  • +
  • Defined in src/pools/abstract-pool.ts:1208
  • +
  • Defined in src/pools/cluster/fixed.ts:124
  • +
    + +
      + +
    • +

      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:940
  • +
  • Defined in src/pools/cluster/fixed.ts:63
  • +
  • Defined in src/pools/abstract-pool.ts:565
  • +
  • Defined in src/pools/abstract-pool.ts:870
  • +
  • Defined in src/pools/abstract-pool.ts:1669
    • - +
    • Gets the worker information given its worker node key.

      @@ -601,12 +664,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:1585
  • +
    + +
      + +
    • +

      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:1627
  • +
  • Defined in src/pools/abstract-pool.ts:667
  • -
    - +
  • Defined in src/pools/cluster/fixed.ts:58
  • +
    +
    +
  • Defined in src/pools/abstract-pool.ts:835
  • +
    + +
      + +
    • +

      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:100
  • +
    + +
      + +
    • +

      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:953
  • +
  • Defined in src/pools/cluster/fixed.ts:93
  • +
  • Defined in src/pools/cluster/fixed.ts:82
  • +
    + +
    +
  • Defined in src/pools/abstract-pool.ts:579
  • +
  • Defined in src/pools/abstract-pool.ts:532
  • +
  • Defined in src/pools/abstract-pool.ts:551
  • +
  • Defined in src/pools/cluster/fixed.ts:53
  • +
    + +
    +
  • Defined in src/pools/abstract-pool.ts:1497
  • @@ -911,95 +1088,63 @@ Can be overridden.

  • type
  • utilization
  • worker
  • +
  • addTaskFunction
  • afterTaskExecutionHook
  • afterWorkerNodeSetup
  • beforeTaskExecutionHook
  • -
  • checkDynamicPoolSize
  • createAndSetupDynamicWorkerNode
  • createAndSetupWorkerNode
  • createWorker
  • +
  • deregisterWorkerMessageListener
  • destroy
  • destroyWorkerNode
  • enableTasksQueue
  • execute
  • flushTasksQueue
  • getWorkerInfo
  • +
  • hasTaskFunction
  • hasWorkerNodeBackPressure
  • internalBusy
  • isMain
  • -
  • listTaskFunctions
  • +
  • listTaskFunctionNames
  • +
  • registerOnceWorkerMessageListener
  • registerWorkerMessageListener
  • +
  • removeTaskFunction
  • sendKillMessageToWorker
  • sendStartupMessageToWorker
  • sendToWorker
  • +
  • setDefaultTaskFunction
  • setTasksQueueOptions
  • setWorkerChoiceStrategy
  • setWorkerChoiceStrategyOptions
  • setupHook
  • +
  • start
  • workerListener
  • +
    -

    Generated using TypeDoc

    -
    \ No newline at end of file +

    Generated using TypeDoc

    +
    \ No newline at end of file