X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Finterfaces%2FIPool.html;h=978eaa3fb72d8d0c123864fd66c5fde93e2a91b9;hb=6b272951b296a2ea26659e9a2fa81bdc6003407f;hp=e898623019741a60ce65884ec8ff5b39a40fcb0d;hpb=3bd6a82e43e11294af91bbd19647944ac740169e;p=poolifier.git diff --git a/docs/interfaces/IPool.html b/docs/interfaces/IPool.html index e8986230..978eaa3f 100644 --- a/docs/interfaces/IPool.html +++ b/docs/interfaces/IPool.html @@ -17,22 +17,26 @@

Interface IPool<Worker, Data, Response>

Contract definition for a poolifier pool.

-
-
+ +
+

Type Parameters

-
+

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

+
+

Hierarchy

+
  • Defined in src/pools/pool.ts:158
  • @@ -50,22 +54,21 @@

    Properties

    - -
    destroy: (() => Promise<void>)
    + +
    destroy: (() => Promise<void>)

    Type declaration

      @@ -73,26 +76,30 @@
      • (): Promise<void>
      • -

        Shutdowns every current worker in this pool.

        +

        Terminate every current worker in this pool.

        -

        Returns Promise<void>

    +
  • Defined in src/pools/pool.ts:193
  • - -
    emitter?: PoolEmitter
    + +
    emitter?: PoolEmitter

    Emitter on which events can be listened to.

    Events that can currently be listened to:

    -
    +
  • Defined in src/pools/pool.ts:181
  • - -
    enableTasksQueue: ((enable, tasksQueueOptions?) => void)
    + +
    enableTasksQueue: ((enable, tasksQueueOptions?) => void)

    Type declaration

    +
  • -
    Optional tasksQueueOptions: TasksQueueOptions
    +
    Optional tasksQueueOptions: TasksQueueOptions

    The worker tasks queue options.

    -
  • -

    Returns void

    +
  • Defined in src/pools/pool.ts:218
  • - -
    execute: ((data?) => Promise<Response>)
    + +
    execute: ((data?, name?) => Promise<Response>)

    Type declaration

    -
    - -
    findFreeWorkerNodeKey: (() => number)
    -
    -

    Type declaration

    -
    +

    Returns Promise<Response>

    Promise that will be fulfilled when the task is completed.

    -

    Returns

    A worker node key if there is one, -1 otherwise.

    +
    +
    + +
    info: PoolInfo
    +

    Pool information.

    -

    Returns number

    +
  • Defined in src/pools/pool.ts:166
  • - -
    setTasksQueueOptions: ((tasksQueueOptions) => void)
    + +
    setTasksQueueOptions: ((tasksQueueOptions) => void)

    Type declaration

    -

    Returns void

    +
  • Defined in src/pools/pool.ts:227
  • - -
    setWorkerChoiceStrategy: ((workerChoiceStrategy, workerChoiceStrategyOptions?) => void)
    + +
    setWorkerChoiceStrategy: ((workerChoiceStrategy, workerChoiceStrategyOptions?) => void)

    Type declaration

    +
  • -
    Optional workerChoiceStrategyOptions: WorkerChoiceStrategyOptions
    +
    Optional workerChoiceStrategyOptions: WorkerChoiceStrategyOptions

    The worker choice strategy options.

    -
  • -

    Returns void

    +
  • Defined in src/pools/pool.ts:200
  • - -
    setWorkerChoiceStrategyOptions: ((workerChoiceStrategyOptions) => void)
    + +
    setWorkerChoiceStrategyOptions: ((workerChoiceStrategyOptions) => void)

    Type declaration

    -

    Returns void

    -
    - -
    type: PoolType
    -

    Pool type.

    -

    If it is 'dynamic', it provides the max property.

    -
    +
  • Defined in src/pools/pool.ts:209
  • - -
    workerNodes: WorkerNode<Worker, Data>[]
    + +
    workerNodes: WorkerNode<Worker, Data>[]

    Pool worker nodes.

    -
    +
  • Defined in src/pools/pool.ts:170
  • +
  • destroy
  • +
  • emitter
  • +
  • enableTasksQueue
  • +
  • execute
  • +
  • info
  • +
  • setTasksQueueOptions
  • +
  • setWorkerChoiceStrategy
  • +
  • setWorkerChoiceStrategyOptions
  • +
  • workerNodes
  • +
  • AbstractPool
  • +
  • AbstractWorker
  • +
  • CircularArray
  • +
  • ClusterWorker
  • +
  • DynamicClusterPool
  • +
  • DynamicThreadPool
  • +
  • FixedClusterPool
  • +
  • FixedThreadPool
  • +
  • PoolEmitter
  • +
  • Queue
  • +
  • ThreadWorker
  • +
  • WorkerChoiceStrategyContext
  • +
  • ClusterPoolOptions
  • +
  • EventLoopUtilizationMeasurementStatistics
  • +
  • IPool
  • +
  • IWorker
  • +
  • IWorkerChoiceStrategy
  • +
  • MeasurementOptions
  • +
  • MeasurementStatistics
  • +
  • MeasurementStatisticsRequirements
  • +
  • MessageValue
  • +
  • PoolInfo
  • +
  • PoolOptions
  • +
  • PromiseResponseWrapper
  • +
  • StrategyPolicy
  • +
  • Task
  • +
  • TaskError
  • +
  • TaskPerformance
  • +
  • TaskStatistics
  • +
  • TaskStatisticsRequirements
  • +
  • TasksQueueOptions
  • +
  • ThreadPoolOptions
  • +
  • WorkerChoiceStrategyOptions
  • +
  • WorkerNode
  • +
  • WorkerOptions
  • +
  • WorkerStatistics
  • +
  • WorkerUsage
  • +
  • ErrorHandler
  • +
  • ExitHandler
  • +
  • KillBehavior
  • +
  • Measurement
  • +
  • MessageHandler
  • +
  • OnlineHandler
  • +
  • PoolEvent
  • +
  • PoolType
  • +
  • TaskFunctions
  • +
  • WorkerAsyncFunction
  • +
  • WorkerChoiceStrategy
  • +
  • WorkerFunction
  • +
  • WorkerSyncFunction
  • +
  • WorkerType
  • +
  • KillBehaviors
  • +
  • Measurements
  • +
  • PoolEvents
  • +
  • PoolTypes
  • +
  • WorkerChoiceStrategies
  • +
  • WorkerTypes
  • +
  • availableParallelism
  • Generated using TypeDoc

    \ No newline at end of file