X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Finterfaces%2FTask.html;h=35ea9207d38d804a882d60a83d9e725344bd9bae;hb=3c2426eb135938bf35b17771f32ed7a39e252173;hp=59aeb8671dc6f4526d4a023059f621b2dc06a43b;hpb=a470bbcf628a548eb345104761dbc9e7d7792809;p=poolifier.git diff --git a/docs/interfaces/Task.html b/docs/interfaces/Task.html index 59aeb867..35ea9207 100644 --- a/docs/interfaces/Task.html +++ b/docs/interfaces/Task.html @@ -1,13 +1,19 @@ -Task | poolifier - v3.1.13

Interface Task<Data>Internal

Message object that is passed as a task between main worker and worker.

-
interface Task {
    data?: Data;
    name?: string;
    taskId?: string;
    timestamp?: number;
    transferList?: TransferListItem[];
}

Type Parameters

  • Data = unknown

    Type of data sent to the worker. This can only be structured-cloneable data.

    -

Hierarchy

Properties

data?: Data

Task input data that will be passed to the worker.

-
name?: string

Task name.

-
taskId?: string

Task UUID.

-
timestamp?: number

Timestamp.

-
transferList?: TransferListItem[]

Array of transferable objects.

-

Generated using TypeDoc

\ No newline at end of file +Task | poolifier - v4.0.8

Interface Task<Data>Internal

Message object that is passed as a task between main worker and worker.

+
interface Task<Data> {
    data?: Data;
    name?: string;
    priority?: number;
    strategy?: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN";
    taskId?: `${string}-${string}-${string}-${string}-${string}`;
    timestamp?: number;
    transferList?: readonly TransferListItem[];
}

Type Parameters

  • Data = unknown

    Type of data sent to the worker. This can only be structured-cloneable data.

    +

Hierarchy (view full)

Properties

data?: Data

Task input data that will be passed to the worker.

+
name?: string

Task name.

+
priority?: number

Task priority. Lower values have higher priority.

+

Default Value

0
+
+
strategy?: "ROUND_ROBIN" | "LEAST_USED" | "LEAST_BUSY" | "LEAST_ELU" | "FAIR_SHARE" | "WEIGHTED_ROUND_ROBIN" | "INTERLEAVED_WEIGHTED_ROUND_ROBIN"

Task worker choice strategy.

+
taskId?: `${string}-${string}-${string}-${string}-${string}`

Task UUID.

+
timestamp?: number

Timestamp.

+
transferList?: readonly TransferListItem[]

Array of transferable objects.

+
\ No newline at end of file