X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FDynamicThreadPool.html;h=23dc786f0a91b757a8400587aa0637f23f5e1c4d;hb=90ee1b18c5477c9caccc2c4015ecfaf84c40e39d;hp=b7fba0c61ae31aaa5d6a377084a30609ae4b1385;hpb=c0b0686de0f8c5483b20b94fac97d2b8175c0556;p=poolifier.git diff --git a/docs/classes/DynamicThreadPool.html b/docs/classes/DynamicThreadPool.html index b7fba0c6..23dc786f 100644 --- a/docs/classes/DynamicThreadPool.html +++ b/docs/classes/DynamicThreadPool.html @@ -40,7 +40,7 @@ When the maximum number of threads is reached, an event is emitted. If you want
Path to an implementation of a ThreadWorker
file, which can be relative or absolute.
Optional
opts: PoolOptions<ThreadWorkerWithMessageChannel> = {}Options for this dynamic thread pool.
Readonly
fileReadonly
maxProtected
nextReadonly
numberReadonly
optsProtected
promiseReadonly
tasksProtected
workerReadonly
workersReadonly
workersProtected
afterHook executed after the worker task promise resolution. +Can be overridden.
+The received message.
+The Promise response.
+Protected
afterProtected
beforeHook executed before the worker task promise resolution. +Can be overridden.
+The worker.
+Protected
chooseChoose a worker for the next task.
+Chooses a worker for the next task.
The default implementation uses a round robin algorithm to distribute the load.
Worker.
@@ -280,7 +324,7 @@ When the maximum number of threads is reached, an event is emitted. If you wantProtected
createProtected
createProtected
decreaseDecrease the number of tasks that the given worker has applied.
-Worker whose tasks are decreased.
-Protected
increaseIncrease the number of tasks that the given worker has applied.
+Initializes tasks usage statistics.
Worker whose tasks are increased.
+The worker.
Protected
internalProtected
internalProtected
isProtected
removeWorker that will be removed.
+The worker that will be removed.
Protected
sendProtected
setupProtected
worker
Constructs a new poolifier dynamic thread pool.