X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Finterfaces%2FIPool.html;h=93f4694004b0290113fc74ab1cb6a676cc29565e;hb=460aaab4b4cb6857827d3e56e11122bffc01db8a;hp=0058f23c23024a3bcc5a484c0584e08d82b1a73a;hpb=67de15a041152a973334839ad2c73284b1b3cbb3;p=poolifier.git
diff --git a/docs/interfaces/IPool.html b/docs/interfaces/IPool.html
index 0058f23c..93f46940 100644
--- a/docs/interfaces/IPool.html
+++ b/docs/interfaces/IPool.html
@@ -42,7 +42,7 @@
+Defined in src/pools/pool.ts:156
@@ -76,7 +76,7 @@
Returns Promise<void>
+Defined in src/pools/pool.ts:191
Optional
Readonly
emitter
@@ -85,10 +85,12 @@
'full'
: Emitted when the pool is dynamic and full.
'busy'
: Emitted when the pool is busy.
+'error'
: Emitted when an uncaught error occurs.
+'taskError'
: Emitted when an error occurs while executing a task.
+Defined in src/pools/pool.ts:179
enableTasksQueue
enableTasksQueue: ((enable, tasksQueueOptions?) => void)
@@ -114,18 +116,18 @@
Returns void
+Defined in src/pools/pool.ts:216
execute
-execute: ((data?) => Promise<Response>)
+execute: ((data?, name?) => Promise<Response>)
Type declaration
-
+
setTasksQueueOptions
setTasksQueueOptions: ((tasksQueueOptions) => void)
@@ -159,7 +172,7 @@
Returns void
+Defined in src/pools/pool.ts:225
setWorkerChoiceStrategy
setWorkerChoiceStrategy: ((workerChoiceStrategy, workerChoiceStrategyOptions?) => void)
@@ -176,7 +189,7 @@
Parameters
-
-
workerChoiceStrategy: "ROUND_ROBIN" | "LESS_USED" | "LESS_BUSY" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN"
+workerChoiceStrategy: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN"
-
@@ -185,7 +198,7 @@
Returns void
+Defined in src/pools/pool.ts:198
setWorkerChoiceStrategyOptions
setWorkerChoiceStrategyOptions: ((workerChoiceStrategyOptions) => void)
@@ -207,22 +220,14 @@
Returns void
-
+Defined in src/pools/pool.ts:207
+Defined in src/pools/pool.ts:168
+PoolTypes
+WorkerChoiceStrategies
+WorkerTypes
Executes the function specified in the worker constructor with the task data input parameter.
+Executes the specified function in the worker constructor with the task data input parameter.
Parameters
@@ -133,11 +135,22 @@Optional
data: DataThe task input data for the specified worker function. This can only be serializable data.
+
+Optional
name: stringThe name of the worker function to execute. If not specified, the default worker function will be executed.
Returns Promise<Response>
Promise that will be fulfilled when the task is completed.