X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FFixedThreadPool.html;h=cf6bea1d45a9aee31df378844a08fd2beda044db;hb=94ab998f44abe7ed2184a0702c45621b06f5641f;hp=0498d0bee1ab114b1f7a2e65b4390afd3d1f9943;hpb=b08b5fc507f21848c9435380edb7d155e92eaaf5;p=poolifier.git diff --git a/docs/classes/FixedThreadPool.html b/docs/classes/FixedThreadPool.html index 0498d0be..cf6bea1d 100644 --- a/docs/classes/FixedThreadPool.html +++ b/docs/classes/FixedThreadPool.html @@ -6,7 +6,7 @@ poolifier +
  • The search index is not available
  • poolifier
    @@ -44,7 +44,7 @@ +
  • Defined in src/pools/thread/fixed.ts:29
  • @@ -58,37 +58,32 @@

    Properties

    Accessors

    Methods

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

    @@ -141,71 +136,61 @@

    Inherit Doc

    +
  • Defined in src/pools/abstract-pool.ts:32
  • -
    filePath: string
    -
    - -
    nextMessageId: number = 0
    -

    Id of the next message.

    +
    filePath: string
    +

    Path to the worker-file.

    +
  • Defined in src/pools/abstract-pool.ts:67
  • -
    numberOfWorkers: number
    +
  • Defined in src/pools/abstract-pool.ts:66
  • -
    -
    - -
    promiseMap: Map<number, PromiseWorkerResponseWrapper<ThreadWorkerWithMessageChannel, Response>> = ...
    -

    The promise map.

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

    The promise response map.

      -
    • key: This is the message Id of each submitted task.
    • -
    • value: An object that contains the worker, the resolve function and the reject function.
    • +
    • key: The message id of each submitted task.
    • +
    • value: An object that contains the worker, the promise resolve and reject callbacks.
    -

    When we receive a message from the worker we get a map entry and resolve/reject the promise based on the message.

    +

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

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

    Worker choice strategy instance implementing the worker choice algorithm.

    -

    Default to a strategy implementing a round robin algorithm.

    +

    Worker choice strategy context referencing a worker choice algorithm implementation.

    +

    Default to a round robin algorithm.

    +
  • Defined in src/pools/abstract-pool.ts:52
  • - +
    workers: WorkerType<ThreadWorkerWithMessageChannel>[] = []

    Inherit Doc

    -
    - -
    workersTasksUsage: Map<ThreadWorkerWithMessageChannel, TasksUsage> = ...
    -
    -

    Inherit Doc

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

    @@ -218,18 +203,29 @@

    Returns boolean

    -
    - -
    +
    + +
    +
    + +
      +
    • get numberOfRunningTasks(): number
    • +
    • +

      Number of tasks concurrently running in the pool.

      +

      Returns number

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

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

      @@ -255,17 +251,17 @@ Can be overridden.

      Parameters

      Returns void

    +
  • Defined in src/pools/abstract-pool.ts:268
  • -
    - +
  • Defined in src/pools/thread/fixed.ts:85
  • +
    +
      - +
    • Hook executed before the worker task promise resolution. Can be overridden.

      @@ -294,27 +290,27 @@ Can be overridden.

      Parameters

      Returns void

    +
  • Defined in src/pools/abstract-pool.ts:257
  • +
  • Defined in src/pools/abstract-pool.ts:297
  • +
  • Defined in src/pools/abstract-pool.ts:363
  • +
  • Defined in src/pools/thread/fixed.ts:78
  • +
  • Defined in src/pools/abstract-pool.ts:220
  • +
  • Defined in src/pools/thread/fixed.ts:54
  • -
    - -
    -
    - -
    -
    - +
  • Defined in src/pools/abstract-pool.ts:204
  • +
    +
    -
    - -
    -
    - -
    -
    - +
  • Defined in src/pools/abstract-pool.ts:197
  • +
    +
    +
  • Defined in src/pools/abstract-pool.ts:189
  • +
  • Defined in src/pools/thread/fixed.ts:49
  • +
  • Defined in src/pools/thread/fixed.ts:70
  • +
  • Defined in src/pools/abstract-pool.ts:487
  • +
  • Defined in src/pools/thread/fixed.ts:62
  • +
    workerChoiceStrategy: "ROUND_ROBIN" | "LESS_USED" | "LESS_BUSY" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN"

    Returns void

    +
  • Defined in src/pools/abstract-pool.ts:164
  • +
  • Defined in src/pools/abstract-pool.ts:242
  • +
  • Defined in src/pools/abstract-pool.ts:392