@taskforcesh/bullmq-pro - v7.38.2
    Preparing search index...

    Class JobPro<DataType, ReturnType, NameType>

    Type Parameters

    • DataType = any
    • ReturnType = any
    • NameType extends string = string

    Hierarchy

    Index

    Constructors

    Methods

    • Moves a job to the completed queue. Returned job to be used with Queue.prototype.nextJobFromJobData.

      Parameters

      • returnValue: ReturnType

        The jobs success message.

      • token: string

        Worker token used to acquire completed job.

      • fetchNext: boolean = true

        True when wanting to fetch the next job.

      Returns Promise<JobData | []>

      Returns the jobData of the next job in the waiting queue.

    • Moves a job to the failed queue.

      Parameters

      • err: Error

        the jobs error message.

      • token: string

        token to check job is locked by current worker

      • fetchNext: boolean = false

        true when wanting to fetch the next job

      Returns Promise<void>

      void