X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FFixedThreadPool.html;h=72a84a2578dbe8615aa2afbd66060139dbc043ae;hb=761b0c73be0bf581f50a78123913f933bd405f52;hp=99e58960595f7e3dedebb3f695aec495ed371d82;hpb=21402562176f7550bcd9ba620cf551972fca6e98;p=poolifier.git diff --git a/docs/classes/FixedThreadPool.html b/docs/classes/FixedThreadPool.html index 99e58960..72a84a25 100644 --- a/docs/classes/FixedThreadPool.html +++ b/docs/classes/FixedThreadPool.html @@ -1,4 +1,4 @@ -FixedThreadPool | poolifier
+FixedThreadPool | poolifier
- @@ -97,7 +100,7 @@
-

Returns FixedThreadPool<Data, Response>

Properties

emitter?: PoolEmitter
-
-

Inherit Doc

+
  • 'full': Emitted when the pool is dynamic and full.
  • +
  • 'busy': Emitted when the pool is busy.
  • + +
    filePath: string
    -

    Path to the worker-file.

    +

    Path to the worker file.

    +
  • Defined in src/pools/abstract-pool.ts:77
  • numberOfWorkers: number

    Number of workers that this pool should manage.

    +
  • Defined in src/pools/abstract-pool.ts:76
  • Options for the pool.

    +
  • Defined in src/pools/abstract-pool.ts:78
  • -
    promiseResponseMap: Map<string, PromiseResponseWrapper<ThreadWorkerWithMessageChannel, Response>> = ...
    +
    promiseResponseMap: Map<string, PromiseResponseWrapper<ThreadWorkerWithMessageChannel, Response>> = ...

    The execution response promise map.

    • key: The message id of each submitted task.
    • @@ -171,50 +179,52 @@

    When we receive a message from the worker, we get a map entry with the promise resolve/reject bound to the message id.

    +
  • Defined in src/pools/abstract-pool.ts:52
  • -
    workerChoiceStrategyContext: WorkerChoiceStrategyContext<ThreadWorkerWithMessageChannel, Data, Response>
    +
    workerChoiceStrategyContext: WorkerChoiceStrategyContext<ThreadWorkerWithMessageChannel, Data, Response>

    Worker choice strategy context referencing a worker choice algorithm implementation.

    Default to a round robin algorithm.

    +
  • Defined in src/pools/abstract-pool.ts:62
  • -
    workerNodes: WorkerNode<ThreadWorkerWithMessageChannel, Data>[] = []
    -
    -

    Inherit Doc

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

    -
    - -
    +
    + +
    • get full(): boolean
    • -
      -

      Inherit Doc

      +

      Whether the pool is full or not.

      +

      The pool filling boolean status.

      +

      Returns boolean

    +
  • Defined in src/pools/thread/fixed.ts:100
  • +
  • Defined in src/pools/abstract-pool.ts:195
  • +
  • Defined in src/pools/abstract-pool.ts:185
  • +
  • Defined in src/pools/thread/fixed.ts:95
  • Methods

    -
    - +
    +
      - +
    • -

      Hook executed after the worker task promise resolution. +

      Hook executed after the worker task execution. Can be overridden.

      @@ -266,35 +277,38 @@ Can be overridden.

      The worker.

    • -
      message: MessageValue<Response, unknown>
      +
      message: MessageValue<Response, unknown>

      The received message.

    Returns void

    +
  • Defined in src/pools/abstract-pool.ts:389
  • Returns void

    -
    - +
  • Defined in src/pools/thread/fixed.ts:85
  • +
    +
      - +
    • -

      Hook executed before the worker task promise resolution. +

      Hook executed before the worker task execution. Can be overridden.

      @@ -305,23 +319,23 @@ Can be overridden.

      The worker node key.

    Returns void

    +
  • Defined in src/pools/abstract-pool.ts:378
  • +
  • Defined in src/pools/abstract-pool.ts:422
  • +
  • Defined in src/pools/abstract-pool.ts:484
  • +
  • Defined in src/pools/thread/fixed.ts:78
  • -
    - -
    +
    + +

    Returns Promise<void>

    +
  • Defined in src/pools/thread/fixed.ts:54
  • +
    + +
    +

    Returns Promise<Response>

    +
  • Defined in src/pools/abstract-pool.ts:310
  • +
  • Defined in src/pools/abstract-pool.ts:303
  • +
  • Defined in src/pools/abstract-pool.ts:298
  • -
    - -
    +
    + +
    +
  • Defined in src/pools/thread/fixed.ts:70
  • +
    + +

    Returns void

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

    Returns void

    +
    + +
    +
  • Defined in src/pools/abstract-pool.ts:244
  • +
  • Defined in src/pools/abstract-pool.ts:363
  • - +
    +
    -
    +
  • constructor
  • +
  • emitter
  • +
  • filePath
  • +
  • numberOfWorkers
  • +
  • opts
  • +
  • promiseResponseMap
  • +
  • workerChoiceStrategyContext
  • +
  • workerNodes
  • +
  • busy
  • +
  • full
  • +
  • numberOfQueuedTasks
  • +
  • numberOfRunningTasks
  • +
  • type
  • +
  • afterTaskExecutionHook
  • +
  • afterWorkerSetup
  • +
  • beforeTaskExecutionHook
  • +
  • chooseWorkerNode
  • +
  • createAndSetupWorker
  • +
  • createWorker
  • +
  • destroy
  • +
  • destroyWorker
  • +
  • enableTasksQueue
  • +
  • execute
  • +
  • findFreeWorkerNodeKey
  • +
  • internalBusy
  • +
  • isMain
  • +
  • registerWorkerMessageListener
  • +
  • sendToWorker
  • +
  • setTasksQueueOptions
  • +
  • setWorkerChoiceStrategy
  • +
  • setWorkerChoiceStrategyOptions
  • +
  • setupHook
  • +
  • workerListener
  • + +

    Generated using TypeDoc

    -
    \ No newline at end of file +
    \ No newline at end of file