Skip to content

Queue.running

Grant Carthew edited this page Aug 19, 2016 · 2 revisions

Property Details

Usage: Read Only

Get: Number

  • Returns the total number of jobs currently being processed by this Queue object.

Example:

const Queue = require('rethinkdb-job-queue')
const q = new Queue()
let runningJobs = q.running
// runningJobs === 0

Description

This is a great property for just finding out what the Queue object is doing. If you have set the Queue.concurrency value to 400 and the Queue.running property is reporting 150, you know the queue is down to its last few jobs.

You could also use the Queue.summary method call to get the sum of the added, failed, and or active job status numbers and report progress. Take note that the Queue.running property will only show total running jobs for this Queue object, not all Queue objects.

Main

How It Works

Contributing

API

Queue Methods

Queue Properties

Queue Events

Job Methods

Job Properties

Documentation

Clone this wiki locally