X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;ds=sidebyside;f=docs%2Fclasses%2FAbstractPool.html;h=e306ebe9c5021637043ffb8fb5f345c46cc09b4e;hb=4e1212db1d198963828820471bde6902277d0388;hp=fed14871d0bf865335550610105d45cdbd2823d4;hpb=8ad621cc1d32ed396fca3ef2ec48337e42d2dcc2;p=poolifier.git
diff --git a/docs/classes/AbstractPool.html b/docs/classes/AbstractPool.html
index fed14871..e306ebe9 100644
--- a/docs/classes/AbstractPool.html
+++ b/docs/classes/AbstractPool.html
@@ -1,13 +1,13 @@
-
AbstractPool | poolifier - v2.6.25
@@ -49,31 +49,33 @@
- IPool<Worker, Data, Response>
+
Defined in src/pools/abstract-pool.ts:59
- Index
+ Index
Constructors
-constructor
+
Properties
-emitter?
+
Accessors
-busy
+
Constructors
-constructor
+constructor
- new AbstractPool<Worker, Data, Response>(numberOfWorkers, filePath, opts): AbstractPool<Worker, Data, Response>
-
@@ -177,7 +191,7 @@
Returns AbstractPool<Worker, Data, Response>
+
Defined in src/pools/abstract-pool.ts:115
Protected
Readonly
filePath
filePath: string
@@ -204,7 +220,15 @@
+
Defined in src/pools/abstract-pool.ts:117
+
+Protected
Optional
Readonly
max
+max?: number
+
+
Protected
Readonly
numberOfWorkers
numberOfWorkers: number
@@ -212,7 +236,7 @@
+
Defined in src/pools/abstract-pool.ts:116
Protected
Readonly
opts
@@ -220,7 +244,7 @@
+
Defined in src/pools/abstract-pool.ts:118
Protected
promiseResponseMap
@@ -233,7 +257,7 @@
+Defined in src/pools/abstract-pool.ts:78
Private
Readonly
startTimestamp
startTimestamp: number
@@ -241,7 +265,15 @@
+
Defined in src/pools/abstract-pool.ts:106
+
+Private
started
+started: boolean
+
+
Private
Readonly
starting
starting: boolean
@@ -249,7 +281,7 @@
+
Defined in src/pools/abstract-pool.ts:98
Protected
workerChoiceStrategyContext
@@ -257,16 +289,16 @@
+Defined in src/pools/abstract-pool.ts:84
-Readonly
workerNodes
+Readonly
Internal
workerNodes
+Defined in src/pools/abstract-pool.ts:65
Protected
full
@@ -292,7 +324,7 @@
Returns boolean
+Defined in src/pools/abstract-pool.ts:689
+Defined in src/pools/abstract-pool.ts:350
-Protected
Abstract
maxSize
+Protected
maxSize
- get maxSize(): number
-
@@ -315,9 +347,9 @@
Returns number
+Defined in src/pools/abstract-pool.ts:562
-Protected
Abstract
minSize
+Protected
minSize
- get minSize(): number
-
@@ -326,7 +358,7 @@
Returns number
+Defined in src/pools/abstract-pool.ts:555
Private
ready
@@ -337,7 +369,7 @@
Returns boolean
+Defined in src/pools/abstract-pool.ts:507
Protected
Abstract
type
@@ -349,7 +381,7 @@
Returns "fixed" | "dynamic"
+Defined in src/pools/abstract-pool.ts:545
+Defined in src/pools/abstract-pool.ts:524
Protected
Abstract
worker
@@ -372,7 +404,7 @@
Returns "thread" | "cluster"
+Defined in src/pools/abstract-pool.ts:550
Protected
afterTaskExecutionHook
@@ -421,7 +453,7 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:888
Protected
afterWorkerNodeSetup
@@ -441,7 +473,7 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:1162
Protected
beforeTaskExecutionHook
@@ -466,7 +498,7 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:858
Private
buildTasksQueueOptions
@@ -479,15 +511,31 @@ Can be overridden.
-
+
+Private
checkAndEmitDynamicWorkerCreationEvents
-- checkAndEmitEvents(): void
+- checkAndEmitDynamicWorkerCreationEvents(): void
-
Returns void
+Defined in src/pools/abstract-pool.ts:1393
+
+Private
checkAndEmitTaskExecutionEvents
+
+- checkAndEmitTaskExecutionEvents(): void
+-
+
Returns void
+
+Private
checkAndEmitTaskQueuingEvents
+
+- checkAndEmitTaskQueuingEvents(): void
+-
+
Returns void
Protected
checkDynamicPoolSize
@@ -502,7 +550,7 @@ Can be overridden.
max: number
Returns void
+Defined in src/pools/abstract-pool.ts:187
Private
checkFilePath
@@ -515,7 +563,7 @@ Can be overridden.
filePath: string
Returns void
+Defined in src/pools/abstract-pool.ts:156
Private
checkMessageWorkerId
+Defined in src/pools/abstract-pool.ts:572
Private
checkNumberOfWorkers
@@ -549,7 +597,7 @@ Can be overridden.
numberOfWorkers: number
Returns void
+Defined in src/pools/abstract-pool.ts:169
Private
checkPoolOptions
@@ -562,7 +610,7 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:213
Private
checkValidTasksQueueOptions
@@ -575,7 +623,7 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:295
Private
checkValidWorkerChoiceStrategy
@@ -588,7 +636,7 @@ Can be overridden.
workerChoiceStrategy: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN"
Returns void
+Defined in src/pools/abstract-pool.ts:241
Private
checkValidWorkerChoiceStrategyOptions
@@ -601,7 +649,7 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:251
Private
chooseWorkerNode
@@ -614,7 +662,7 @@ Can be overridden.
+Defined in src/pools/abstract-pool.ts:1015
Protected
createAndSetupDynamicWorkerNode
@@ -626,7 +674,7 @@ Can be overridden.
+Defined in src/pools/abstract-pool.ts:1105
Protected
createAndSetupWorkerNode
@@ -638,7 +686,7 @@ Can be overridden.
+Defined in src/pools/abstract-pool.ts:1061
Protected
Abstract
createWorker
@@ -650,7 +698,7 @@ Can be overridden.
+Defined in src/pools/abstract-pool.ts:1054
Private
dequeueTask
@@ -663,7 +711,7 @@ Can be overridden.
workerNodeKey: number
Returns undefined | Task<Data>
+Defined in src/pools/abstract-pool.ts:1483
+Defined in src/pools/abstract-pool.ts:803
Protected
Abstract
destroyWorkerNode
@@ -694,32 +742,32 @@ Can be overridden.
Returns Promise<void>
+Defined in src/pools/abstract-pool.ts:834
enableTasksQueue
- enableTasksQueue(enable, tasksQueueOptions?): void
-
-
Returns void
+Defined in src/pools/abstract-pool.ts:1353
Private
handleWorkerReadyResponse
@@ -896,7 +944,36 @@ Can be overridden.
message: MessageValue<Response, unknown>
Returns void
+Defined in src/pools/abstract-pool.ts:1339
+
+Private
hasBackPressure
+
+- hasBackPressure(): boolean
+-
+
Returns boolean
+
+hasWorkerNodeBackPressure
+
Protected
internalBusy
@@ -908,7 +985,7 @@ Can be overridden.
+Defined in src/pools/abstract-pool.ts:705
Protected
Abstract
isMain
@@ -919,7 +996,20 @@ Can be overridden.
Returns boolean
+Defined in src/pools/abstract-pool.ts:849
+
Private
redistributeQueuedTasks
@@ -932,7 +1022,7 @@ Can be overridden.
workerNodeKey: number
Returns void
+Defined in src/pools/abstract-pool.ts:1202
Protected
Abstract
registerWorkerMessageListener
@@ -972,7 +1062,7 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:1149
Private
removeWorkerNode
@@ -991,7 +1081,22 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:1440
+
+Protected
sendKillMessageToWorker
+
+- sendKillMessageToWorker(workerNodeKey, workerId): Promise<void>
+-
+
+
Parameters
+
+-
+
workerNodeKey: number
+-
+
workerId: number
+Returns Promise<void>
Protected
Abstract
sendStartupMessageToWorker
@@ -1010,7 +1115,26 @@ Can be overridden.
Returns void
+Defined in src/pools/abstract-pool.ts:1182
+
+Private
sendStatisticsMessageToWorker
+
+- sendStatisticsMessageToWorker(workerNodeKey): void
+-
+
+
+
Parameters
+
+-
+
workerNodeKey: number
+
+
+Returns void
+
Protected
Abstract
sendToWorker
@@ -1039,46 +1163,40 @@ Can be overridden.
Returns void
-
-Private
sendWorkerStatisticsMessageToWorker
-
-- sendWorkerStatisticsMessageToWorker(workerNodeKey): void
--
-
-
-
Parameters
-
--
-
workerNodeKey: number
-
-
-Returns void
-
+Defined in src/pools/abstract-pool.ts:1043
setTasksQueueOptions
- setTasksQueueOptions(tasksQueueOptions): void
-
-
Returns void
+Defined in src/pools/abstract-pool.ts:975
Private
updateRunTimeWorkerUsage
@@ -1198,7 +1375,7 @@ Can be overridden.
message: MessageValue<Response, unknown>
Returns void
+Defined in src/pools/abstract-pool.ts:948
Private
updateTaskStatisticsWorkerUsage
@@ -1213,7 +1390,22 @@ Can be overridden.
message: MessageValue<Response, unknown>
Returns void
+Defined in src/pools/abstract-pool.ts:930
+
+Private
updateTaskStolenStatisticsWorkerUsage
+
+- updateTaskStolenStatisticsWorkerUsage(workerNodeKey, taskName): void
+-
+
+
Parameters
+
+-
+
workerNodeKey: number
+-
+
taskName: string
+Returns void
Private
updateWaitTimeWorkerUsage
@@ -1228,7 +1420,7 @@ Can be overridden.
task: Task<Data>
Returns void
+Defined in src/pools/abstract-pool.ts:962
Protected
workerListener
@@ -1255,20 +1447,20 @@ Can be overridden.
+Defined in src/pools/abstract-pool.ts:1321
+
-
\ No newline at end of file
+Generated using TypeDoc
+
\ No newline at end of file
Emitter on which events can be listened to.
Events that can currently be listened to:
-
-
+
+
+
+
'full'
: Emitted when the pool is dynamic and the number of workers created has reached the maximum size expected.'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.'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).