# automattic/kue

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/automattic-kue).**

9,437 stars · 858 forks · JavaScript · MIT

## Links

- GitHub: https://github.com/Automattic/kue
- Homepage: http://automattic.github.io/kue
- awesome-repositories: https://awesome-repositories.com/repository/automattic-kue.md

## Topics

`job-queue` `priority-queue` `worker-queue`

## Description

Kue is a Redis-backed job queue library for Node.js that provides a complete system for defining, scheduling, and processing background work. It stores job metadata and state in Redis lists and sorted sets, enabling persistent, in-memory operations with configurable concurrency control and priority-sorted processing. The library includes a RESTful HTTP API for managing jobs and a web-based monitoring dashboard for inspecting job status, progress, and logs.

The system distinguishes itself through its event-driven worker model, where workers listen for job events via Redis pub/sub and process jobs asynchronously using callbacks. It supports delayed job scheduling with automatic promotion to the active queue, priority-based execution ordering, and fault-tolerant processing with configurable retries, timeouts, and recovery of stuck jobs after crashes. Graceful shutdown protocols allow workers to finish current jobs within a configurable timeout, while pause and resume controls provide administrative flexibility.

Kue offers job lifecycle monitoring through event listening for enqueue, start, completion, and failure events, along with per-job progress tracking and logging. The web dashboard provides real-time visibility into queue state, and search indexing enables querying jobs by their data content through REST endpoints. The system includes job cleanup for automatic removal of completed work, stuck job recovery on startup, and support for distributing processing across multiple CPU cores using Node.js Cluster. Security measures protect the web interface and API with TLS and HTTP basic authentication.

## Tags

### Software Engineering & Architecture

- [Redis-Backed Background Job Libraries](https://awesome-repositories.com/f/software-engineering-architecture/redis-backed-background-job-libraries.md) — Runs background job queues backed by Redis for persistence, reliability, and fast in-memory operations.
- [Redis-Backed Queues](https://awesome-repositories.com/f/software-engineering-architecture/distributed-task-queues/redis-backed-queues.md) — Stores job metadata and state in Redis lists and sorted sets for persistence and atomic operations.
- [Event-Driven Callbacks](https://awesome-repositories.com/f/software-engineering-architecture/event-driven-callbacks.md) — Workers listen for job events via Redis pub/sub and process jobs asynchronously using callbacks.
- [Fault Tolerance Implementation](https://awesome-repositories.com/f/software-engineering-architecture/fault-tolerance-strategies/fault-tolerance-implementation.md) — Handles job failures with automatic retries, timeouts, and recovery of stuck jobs after crashes.
- [Automation Job APIs](https://awesome-repositories.com/f/software-engineering-architecture/integration-extensibility/api-design-management/api-integration-strategies/restful-workflow-apis/automation-job-apis.md) — Provides a RESTful JSON API for creating, retrieving, deleting, and listing background jobs. ([source](https://cdn.jsdelivr.net/gh/automattic/kue@master/README.md))
- [Queue Monitoring Dashboards](https://awesome-repositories.com/f/software-engineering-architecture/distributed-task-queues/redis-backed-queues/queue-monitoring-dashboards.md) — Ships a browser dashboard for viewing job status, progress, logs, and managing queue operations in real time.
- [Job Management APIs](https://awesome-repositories.com/f/software-engineering-architecture/integration-extensibility/api-design-management/api-integration-strategies/restful-workflow-apis/automation-job-apis/job-management-apis.md) — Provides a JSON HTTP API for creating, inspecting, and deleting queued jobs with search and filtering.

### DevOps & Infrastructure

- [Delayed Task Scheduling](https://awesome-repositories.com/f/devops-infrastructure/automation-orchestration/task-execution-frameworks/task-job-management/task-schedulers/delayed-task-scheduling.md) — Schedules jobs to execute at a future time or after a specified delay without manual intervention.
- [Per-Type Concurrency Limits](https://awesome-repositories.com/f/devops-infrastructure/job-concurrency-controllers/per-type-concurrency-limits.md) — Implements configurable per-job-type concurrency limits using Redis-backed semaphores.
- [Job Priority Management](https://awesome-repositories.com/f/devops-infrastructure/job-priority-management.md) — Manages and processes jobs with configurable priority levels to ensure high-priority tasks execute first.
- [Priority-Based Job Schedulers](https://awesome-repositories.com/f/devops-infrastructure/job-priority-management/priority-based-job-schedulers.md) — Executes delayed and prioritized work items with configurable concurrency and retry logic.
- [Redis Sorted Set Priority Ordering](https://awesome-repositories.com/f/devops-infrastructure/job-priority-management/redis-sorted-set-priority-ordering.md) — Orders jobs by priority using Redis sorted sets for deterministic dequeuing.
- [Concurrent Job Schedulers](https://awesome-repositories.com/f/devops-infrastructure/job-scheduling/concurrent-job-schedulers.md) — Runs multiple jobs of the same type in parallel with configurable concurrency limits.
- [Node.js Cluster Distribution](https://awesome-repositories.com/f/devops-infrastructure/distributed-job-execution/node-js-cluster-distribution.md) — Distributes job processing across multiple CPU cores using Node.js Cluster. ([source](https://cdn.jsdelivr.net/gh/automattic/kue@master/README.md))
- [Graceful Shutdowns](https://awesome-repositories.com/f/devops-infrastructure/graceful-shutdowns.md) — Signals workers to finish current jobs and stop accepting new work within a configurable timeout.
- [Completed Job Cleanups](https://awesome-repositories.com/f/devops-infrastructure/job-queues/completed-job-cleanups.md) — Removes a job from Redis automatically upon completion to free memory. ([source](https://cdn.jsdelivr.net/gh/automattic/kue@master/README.md))
- [Automatic Retry Mechanisms](https://awesome-repositories.com/f/devops-infrastructure/job-scheduling/automatic-retry-mechanisms.md) — Automatically re-attempts jobs after failure with configurable retry counts and delays between attempts. ([source](https://cdn.jsdelivr.net/gh/automattic/kue@master/README.md))
- [Stalled Job Recovery](https://awesome-repositories.com/f/devops-infrastructure/job-scheduling/stalled-job-recovery.md) — Re-queues jobs left in an active state after a crash by scanning for stale entries on startup.

### Programming Languages & Runtimes

- [Node.js Job Schedulers](https://awesome-repositories.com/f/programming-languages-runtimes/node-js-job-schedulers.md) — A Node.js library for defining, queuing, and processing background jobs with lifecycle event hooks.

### System Administration & Monitoring

- [Background Job Dashboards](https://awesome-repositories.com/f/system-administration-monitoring/background-job-dashboards.md) — Provides a browser UI to inspect job status, progress, logs, and search job data.

### Web Development

- [Job Status Monitoring](https://awesome-repositories.com/f/web-development/reactive-networking/progress-tracking/job-status-monitoring.md) — Tracks job progress, logs messages, and views status through a web dashboard for observability.
- [RESTful API Designs](https://awesome-repositories.com/f/web-development/restful-api-designs.md) — Exposes job management operations through a JSON HTTP interface built on top of the queue core.
- [Job Lifecycle](https://awesome-repositories.com/f/web-development/event-listeners/job-lifecycle.md) — Subscribes to lifecycle events like enqueue, start, complete, or failure on jobs or the queue. ([source](https://cdn.jsdelivr.net/gh/automattic/kue@master/README.md))

### Security & Cryptography

- [Web Interface Protections](https://awesome-repositories.com/f/security-cryptography/interface-access-security/web-interface-protections.md) — Ships TLS and HTTP basic authentication middleware to protect the web dashboard and REST API. ([source](https://cdn.jsdelivr.net/gh/automattic/kue@master/README.md))

### Part of an Awesome List

- [Open-source projects made by Iranian developers](https://awesome-repositories.com/f/awesome-lists/more/open-source-projects-made-by-iranian-developers.md) — Listed in the “Open-source projects made by Iranian developers” section of the Github Do Not Ban Us awesome list.
