Options
All
  • Public
  • Public/Protected
  • All
Menu

bullmq

Index

Enumerations

Classes

Interfaces

Type aliases

Variables

Functions

Type aliases

ActiveEventCallback3<T>: (job: Job, jobPromise?: JobPromise3) => void

Type parameters

  • T = any

Type declaration

BackoffFunction: (attemptsMade?: number, err?: Error, job?: Job) => number

Type declaration

    • (attemptsMade?: number, err?: Error, job?: Job): number
    • Parameters

      • Optional attemptsMade: number
      • Optional err: Error
      • Optional job: Job

      Returns number

BulkJobOptions: Omit<JobsOptions, "repeat">
CleanedEventCallback3<T>: (jobs: Job[], status: JobStatusClean3) => void

Type parameters

  • T = any

Type declaration

ClusterOptions: IORedis.ClusterOptions & BaseOptions
CompletedEventCallback3<T>: (job: Job, result: any) => void

Type parameters

  • T = any

Type declaration

    • (job: Job, result: any): void
    • Parameters

      • job: Job
      • result: any

      Returns void

ConnectionOptions: RedisOptions | ClusterOptions | IORedis.Redis | IORedis.Cluster
EntryId: string
EntryRaw: [EntryId, string[]]
ErrorEventCallback3: (error: Error) => void

Type declaration

    • (error: Error): void
    • Parameters

      • error: Error

      Returns void

EventCallback3: () => void

Type declaration

    • (): void
    • Returns void

FailedEventCallback3<T>: (job: Job, error: Error) => void

Type parameters

  • T = any

Type declaration

    • (job: Job, error: Error): void
    • Parameters

      • job: Job
      • error: Error

      Returns void

FinishedPropValAttribute: "returnvalue" | "failedReason"
FinishedStatus: "completed" | "failed"
FlowQueuesOpts: Record<string, Omit<QueueOptions, "connection" | "prefix">>
JobData: [JobJsonRaw | number, string?]
JobJsonSandbox: JobJson & { parent?: ParentKeys; prefix: string; queueName: string }
JobState: FinishedStatus | "active" | "delayed" | "waiting" | "waiting-children"
JobStatusClean3: "completed" | "wait" | "active" | "delayed" | "paused" | "failed"
JobType: JobState | "paused" | "repeat" | "wait"
KeysMap: { [ index in string]: string }
MinimalQueue: Pick<QueueBase, "name" | "client" | "toKey" | "keys" | "opts" | "closing" | "waitUntilReady" | "removeListener" | "emit" | "on" | "redisVersion">
ParentOpts: { parentDependenciesKey?: string; parentKey?: string; waitChildrenKey?: string }

Type declaration

  • Optional parentDependenciesKey?: string
  • Optional parentKey?: string
  • Optional waitChildrenKey?: string
Processor<T, R, N>: (job: Job<T, R, N>, token?: string) => Promise<R>

Type parameters

  • T = any

  • R = any

  • N: string = string

Type declaration

    • (job: Job<T, R, N>, token?: string): Promise<R>
    • An async function that receives Jobs and handles them.

      Parameters

      • job: Job<T, R, N>
      • Optional token: string

      Returns Promise<R>

ProgressEventCallback3<T>: (job: Job, progress: any) => void

Type parameters

  • T = any

Type declaration

    • (job: Job, progress: any): void
    • Parameters

      • job: Job
      • progress: any

      Returns void

RedisClient: Redis | Cluster
RedisOptions: IORedis.RedisOptions & BaseOptions
RemovedEventCallback3<T>: (job: Job) => void

Type parameters

  • T = any

Type declaration

    • (job: Job): void
    • Parameters

      Returns void

SandboxedJobProcessor<T, R>: ((job: SandboxedJob<T, R>) => R | PromiseLike<R>) | ((job: SandboxedJob<T, R>, callback: (error: unknown, result: R) => void) => void)

Type parameters

  • T = any

  • R = any

StalledEventCallback3<T>: (job: Job) => void

Type parameters

  • T = any

Type declaration

    • (job: Job): void
    • Parameters

      Returns void

StreamName: string
StreamReadRaw: [StreamName, EntryRaw[]][]
WaitingEventCallback3: (jobId: string) => void

Type declaration

    • (jobId: string): void
    • Parameters

      • jobId: string

      Returns void

Variables

DELAY_TIME_1: 100 = 100
DELAY_TIME_5: 5000 = 5000
QUEUE_EVENT_SUFFIX: ":qe" = ':qe'
QUEUE_SCHEDULER_SUFFIX: ":qs" = ':qs'
WORKER_SUFFIX: "" = ''
clientCommandMessageReg: RegExp = ...
errorObject: {} = ...

Type declaration

  • [index: string]: any
scriptLoader: ScriptLoader = ...

Functions

  • array2obj(arr: string[]): Record<string, string>
  • Parameters

    • arr: string[]

    Returns Record<string, string>

  • asyncSend<T>(proc: T, msg: any): Promise<void>
  • Type parameters

    • T: procSendLike

    Parameters

    • proc: T
    • msg: any

    Returns Promise<void>

  • delay(ms: number): Promise<void>
  • Parameters

    • ms: number

    Returns Promise<void>

  • getParentKey(opts: { id: string; queue: string }): string
  • Parameters

    • opts: { id: string; queue: string }
      • id: string
      • queue: string

    Returns string

  • isEmpty(obj: object): boolean
  • Parameters

    • obj: object

    Returns boolean

  • isNotConnectionError(error: Error): boolean
  • Parameters

    • error: Error

    Returns boolean

  • isRedisCluster(obj: unknown): obj is Cluster
  • Parameters

    • obj: unknown

    Returns obj is Cluster

  • isRedisInstance(obj: any): obj is Redis | Cluster
  • Parameters

    • obj: any

    Returns obj is Redis | Cluster

  • isRedisVersionLowerThan(currentVersion: string, minimumVersion: string): boolean
  • Parameters

    • currentVersion: string
    • minimumVersion: string

    Returns boolean

  • killAsync(child: ChildProcess, signal?: "SIGTERM" | "SIGKILL", timeoutMs?: number): Promise<void>
  • Sends a kill signal to a child resolving when the child has exited, resorting to SIGKILL if the given timeout is reached

    Parameters

    • child: ChildProcess
    • signal: "SIGTERM" | "SIGKILL" = 'SIGKILL'
    • timeoutMs: number = undefined

    Returns Promise<void>

  • lengthInUtf8Bytes(str: string): number
  • parentSend(child: ChildProcess, msg: ParentMessage): Promise<void>
  • raw2jobData(raw: any[]): [JobJsonRaw | number, string?] | []
  • removeAllQueueData(client: RedisClient, queueName: string, prefix?: string): Promise<void | boolean>
  • Parameters

    • client: RedisClient
    • queueName: string
    • prefix: string = 'bull'

    Returns Promise<void | boolean>

  • tryCatch(fn: (...args: any) => any, ctx: any, args: any[]): any
  • Parameters

    • fn: (...args: any) => any
        • (...args: any): any
        • Parameters

          • Rest ...args: any

          Returns any

    • ctx: any
    • args: any[]

    Returns any

Generated using TypeDoc