Automattic / Automattic/kue

How to close connection for a job type

Open
#1,218 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
9.4k
Forks
858
PR merge metrics
No merged PRs in 30d

Description

From what I see, Kue is creating new Redis connections for every job type. We have a scenario where we have queues for each user so 200 active users with Redis connections can become an issue - especially as I don't see a way to stop processing a job type, thereby closing its underlying Redis connection.

1) Can the Redis connection be shared - from what I see, Kue cannot currently do this?
2) How can a let Kue know that it should no longer process a job type so they underlying connection to Redis is closed?

Contributor guide

No contributing guide indexed for this repository

Research direction

No files, tests, or entry points are named. Start by tracing how Kue creates Redis connections for each job type and whether it exposes a stop or cleanup operation; then review existing queue and worker documentation. Done would be a clearly scoped answer about connection sharing or job-type shutdown, with any required API behavior defined.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js, redis
Domain
backend, databases
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.