X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FFixedThreadPool.html;h=4fe8d4d8294782ccb3938f560acc16bb1fa607aa;hb=e39450c0889208d6dcde666fc05b95fe7a98ee29;hp=a7b5b27c4ec19ee612dde0598367a1310d42d962;hpb=18ba88e2f8612c6137bf564388ce8f905ae6d4ee;p=poolifier.git diff --git a/docs/classes/FixedThreadPool.html b/docs/classes/FixedThreadPool.html index a7b5b27c..4fe8d4d8 100644 --- a/docs/classes/FixedThreadPool.html +++ b/docs/classes/FixedThreadPool.html @@ -1,4 +1,4 @@ -FixedThreadPool | poolifier
+FixedThreadPool | poolifier
-
+
  • Response = unknown

    -

    Type of response of execution. This can only be serializable data.

    +

    Type of execution response. This can only be serializable data.

  • Hierarchy

    +
  • Defined in src/pools/thread/fixed.ts:29
  • @@ -66,8 +66,8 @@

    Accessors

    -
    busy -full +
    busy +full numberOfQueuedTasks numberOfRunningTasks type @@ -81,12 +81,12 @@ createAndSetupWorker createWorker destroy -destroyWorker +destroyWorker execute findFreeWorkerNodeKey internalBusy isMain -registerWorkerMessageListener +registerWorkerMessageListener sendToWorker setWorkerChoiceStrategy setupHook @@ -97,7 +97,7 @@
    -

    Returns FixedThreadPool<Data, Response>

    +
  • Defined in src/pools/thread/fixed.ts:40
  • 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.

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

    Number of workers that this pool should manage.

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

    +
  • Defined in src/pools/abstract-pool.ts:77
  • -
    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 +176,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:51
  • -
    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:61
  • -
    workerNodes: WorkerNode<ThreadWorkerWithMessageChannel, Data>[] = []
    -
    -

    Inherit Doc

    +
  • Defined in src/pools/abstract-pool.ts:38
  • 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:186
  • +
  • Defined in src/pools/abstract-pool.ts:176
    • -
    • get type(): PoolType
    • +
    • get type(): PoolType
    • -
      -

      Inherit Doc

      -

      Returns PoolType

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

      - +
    • Hook executed after the worker task execution. Can be overridden.

      @@ -266,29 +274,32 @@ 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:335
  • Returns void

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

    +
  • Defined in src/pools/abstract-pool.ts:324
  • +
  • Defined in src/pools/abstract-pool.ts:368
  • +
  • Defined in src/pools/abstract-pool.ts:430
  • +
  • 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:256
  • +
  • Defined in src/pools/abstract-pool.ts:249
  • +
  • Defined in src/pools/abstract-pool.ts:244
  • -
    - -
    +
    + +
    +
  • Defined in src/pools/thread/fixed.ts:70
  • Returns void

    +
  • Defined in src/pools/thread/fixed.ts:62
  • Returns void

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

    Generated using TypeDoc

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