X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Finterfaces%2FWorkerOptions.html;h=f75b4d94b88927fef09356abea2baaf4f081658b;hb=a99f06d1fff8949584cd630bfaa3fa2e3cc3897e;hp=fbbc6468010bc6a7dd24f361e0d772152d306bc4;hpb=cf4c4b77d31b88b45c9f876f6fab553e66000f4d;p=poolifier.git diff --git a/docs/interfaces/WorkerOptions.html b/docs/interfaces/WorkerOptions.html index fbbc6468..f75b4d94 100644 --- a/docs/interfaces/WorkerOptions.html +++ b/docs/interfaces/WorkerOptions.html @@ -1,5 +1,5 @@ -WorkerOptions | poolifier - v3.1.22

Interface WorkerOptions

Options for workers.

-
interface WorkerOptions {
    killBehavior?: "SOFT" | "HARD";
    killHandler?: KillHandler;
    maxInactiveTime?: number;
}

Properties

killBehavior? +WorkerOptions | poolifier - v3.1.27

Interface WorkerOptions

Options for workers.

+
interface WorkerOptions {
    killBehavior?: "SOFT" | "HARD";
    killHandler?: KillHandler;
    maxInactiveTime?: number;
}

Properties

killBehavior?: "SOFT" | "HARD"

killBehavior dictates if your worker will be deleted in case a task is active on it.

@@ -10,9 +10,9 @@

This option only apply to the newly created workers.

Default Value

KillBehaviors.SOFT
 
-
killHandler?: KillHandler

The function to call when a worker is killed.

+
killHandler?: KillHandler

The function to call when a worker is killed.

Default Value

() => {}

-
maxInactiveTime?: number

Maximum waiting time in milliseconds for tasks on newly created workers. It must be greater or equal than 5.

+
maxInactiveTime?: number

Maximum waiting time in milliseconds for tasks on newly created workers. It must be greater or equal than 5.

After this time, newly created workers will be terminated. The last active time of your worker will be updated when it terminates a task.

    @@ -22,4 +22,4 @@ when this timeout expires your tasks is interrupted before completion and remove

Default Value

60000
 
-

Generated using TypeDoc

\ No newline at end of file +

Generated using TypeDoc

\ No newline at end of file