Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface QueueOptions<T, V>

Options of queue.

Type parameters

  • T

  • V

Hierarchy

  • QueueOptions

Index

Properties

Optional concurrency

concurrency: undefined | number

Specifies how many tasks to run simultaneously, default value is 5.

Optional continueOnError

continueOnError: undefined | boolean

If true, will continue processing tasks after error occurred.

handler

handler: QueueHandler<T, V>

Handler to process each task.

Optional key

key: undefined | string

If provided, can avoid adding duplicate tasks with same keys.

Optional maxRetryTimes

maxRetryTimes: undefined | number

Specifies how many times to retry before one task success. If one task's retry times execeed, it will never retry automatically, but you can still retry all failed tasks by calling retry() manually. Setting this option to values > 0 implies continueOnError is true.

Optional tasks

tasks: undefined | T[]

The start task array which will be passed to handler in order.

Generated using TypeDoc