Skip to content

Add BetterQueue to the API section - #1191

Closed
Saiop68 wants to merge 1 commit into
sorrycc:masterfrom
Saiop68:add/better-queue
Closed

Saiop68 wants to merge 1 commit into
sorrycc:masterfrom
Saiop68:add/better-queue

Conversation

@Saiop68

@Saiop68 Saiop68 commented Oct 30, 2026

Copy link
Copy Markdown

Adds BetterQueue next to Bottleneck in the API section.

It's a distributed rate limiter and job queue for Node.js where the queue state lives in Redis rather than in the process. Practical differences from Bottleneck:

  • Cheap limiters. A limiter is a thin handle, so 1000 limiters cost roughly what 10 do.
  • Jobs survive a crash. Another process picks up work a dead worker was holding.
  • Cross-process priority. Ordering is computed server-side, so it holds across the whole fleet.
  • Delayed jobs. scheduleAt() for work that needs to happen later.

The repo includes a benchmark that runs both libraries in separate processes against the same Redis: with 1000 limiters and 51,000 jobs, RSS after the run was 415 MB for Bottleneck and 222 MB for BetterQueue, and throughput was 9,957/s vs 11,456/s.

MIT licensed, TypeScript, 37 tests with CI on Node 18/20/22.

@Saiop68 Saiop68 closed this by deleting the head repository Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant