Options
All
  • Public
  • Public/Protected
  • All
Menu

conveyor-mq

Functions

Const createListener

  • createListener(__namedParameters: object): Promise<object>
  • Parameters

    • __namedParameters: object
      • queue: string
      • redisConfig: object
        • host: string
        • port: number

    Returns Promise<object>

Const createManager

  • createManager(__namedParameters: object): Promise<object>
  • Parameters

    • __namedParameters: object
      • queue: string
      • redisConfig: object
        • host: string
        • port: number

    Returns Promise<object>

Const createOrchestrator

  • createOrchestrator(__namedParameters: object): Promise<object>
  • Parameters

    • __namedParameters: object
      • defaultStallTimeout: number
      • delayedTasksCheckInterval: number
      • queue: string
      • redisConfig: object
        • host: string
        • port: number
      • stalledCheckInterval: number

    Returns Promise<object>

Const createWorker

  • createWorker(__namedParameters: object): Promise<object>
  • Parameters

    • __namedParameters: object
      • autoStart: boolean
      • concurrency: number
      • defaultStallTimeout: number
      • defaultTaskAcknowledgementInterval: undefined | number
      • getRetryDelay: undefined | function
      • handler: function
          • (__namedParameters: object): any
          • Parameters

            • __namedParameters: object
              • task: Task
              • updateTask: function
                  • (taskUpdateData: Partial<Task>): Promise<Task>
                  • Parameters

                    • taskUpdateData: Partial<Task>

                    Returns Promise<Task>

              • updateTaskProgress: function
                  • (progress: any): Promise<Task>
                  • Parameters

                    • progress: any

                    Returns Promise<Task>

            Returns any

      • idleTimeout: number
      • onHandlerError: undefined | function
      • onIdle: undefined | function
      • onReady: undefined | function
      • onTaskError: undefined | function
      • onTaskFailed: undefined | function
      • onTaskSuccess: undefined | function
      • queue: string
      • redisConfig: object
        • host: string
        • port: number
      • removeOnFailed: boolean
      • removeOnSuccess: boolean

    Returns Promise<object>

Const deSerializeWorker

  • deSerializeWorker(workerString: string): Worker
  • Parameters

    • workerString: string

    Returns Worker

Const getWorkers

  • getWorkers(__namedParameters: object): Promise<Worker[]>
  • Parameters

    • __namedParameters: object
      • client: Redis
      • queue: string

    Returns Promise<Worker[]>

Const markTasksFailedMulti

  • markTasksFailedMulti(__namedParameters: object): Task[]
  • Parameters

    • __namedParameters: object
      • multi: Pipeline
      • queue: string
      • remove: undefined | false | true
      • tasksAndErrors: object[]

    Returns Task[]

Const serializeWorker

  • serializeWorker(worker: Worker): string
  • Parameters

    Returns string

Generated using TypeDoc