Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • B bull
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 175
    • Issues 175
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 9
    • Merge requests 9
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • OptimalBits
  • bull
  • Issues
  • #595
Closed
Open
Issue created Jun 29, 2017 by Administrator@rootContributor

[Feature] emit `drained` event when Queue is empty

Created by: marshall007

Currently, there does not appear to be a reliable way to be notified when the queue is done processing all active jobs and there are no other remaining jobs in the queue. It would be nice if a drained event were emitted in this case indicating that there is no remaining work to be done.

Use case is for knowing when it's safe to close/empty/clean up a Queue without missing any jobs.

The only workaround I'm aware of is to manually check the result of getJobCounts() after every completed event.

Assignee
Assign to
Time tracking