Skip to content

Latest commit

 

History

History
30 lines (19 loc) · 1.43 KB

File metadata and controls

30 lines (19 loc) · 1.43 KB
hide_title true
custom_edit_url
pagination_prev
pagination_next

Home > @rushstack/node-core-library > IAsyncParallelismOptions > allowOversubscription

IAsyncParallelismOptions.allowOversubscription property

This option affects the handling of task weights, applying a softer policy that favors maximizing parallelism instead of avoiding overload.

Signature:

allowOversubscription?: boolean;

Default Value

false

Remarks

By default, a new task cannot start executing if doing so would push the total weight above the concurrency limit. Set allowOversubscription to true to relax this rule, allowing a new task to start as long as the current total weight is below the concurrency limit. Either way, a task cannot start if the total weight already equals the concurrency limit; therefore, allowOversubscription has no effect when all tasks have weight 1.

Example: Suppose the concurrency limit is 8, and seven tasks are running whose weights are 1, so the current total weight is 7. If an available task has weight 2, that would push the total weight to 9, exceeding the limit. This task can start only if allowOversubscription is true.