nestjs-bullmq
Implement BullMQ job workflows in NestJS. Use when building queue processors, redis-throttler, Upstash limits, idle polling, stalled jobs, and retention…
от HoangNguyen0403★ 598 звёзд на GitHub
Установить nestjs-bullmq в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
NestJS BullMQ Implementation
Priority: P0 (CRITICAL)
Guidelines
- Set idle polling: Add
drainDelay+stalledInterval+maxStalledCountto every@Processor. DefaultdrainDelay(5 ms) burns 570M Redis commands/day at idle. See patterns.md. - Throttle worker error logs: BullMQ workers emit raw unhandled ReplyErrors on Redis failure (e.g. Upstash rate limits). Always extend
BaseProcessorinstead ofWorkerHostto rate-limit these logs. See patterns.md. - Set job retention: Add
removeOnComplete,removeOnFail,attempts,backoffto everyBullModule.registerQueue. See patterns.md. - Use shared constants: All numeric options live in
src/common/constants/bull-queue.constants.ts. Key constants:QUEUE_DRAIN_DELAY_MS(10 000 ms),QUEUE_STALLED_INTERVAL_MS(60 000 ms). UsegetSharedBullQueueOptionshelper forregisterQueue. Queue/job names go in{feature}.constants.ts. Never inline magic numbers. - Wrap every
queue.add(): Persist DB record first, then enqueue inside try-catch. Redis errors must not surface as 500s. See patterns.md. - Throttler fail-open:
ThrottlerGuardregistered as globalAPP_GUARD— Redis blip propagates errors to ALL HTTP routes.RedisThrottlerStorage.increment()must catch all Redis errors and return fail-open pass-through record. Redis blip must not kill all HTTP routes. See patterns.md. - Guard new queues: Follow
isRedisEnabled()conditional + mock token pattern in every module. NestJS DI throws on startup without mock. - Keep processor and cron: Cron schedules; processor executes. Both always required — they complementary. See patterns.md.
- Use local Redis in dev: Never point dev machines at Upstash — idle workers exhaust free tier (500K/day) in minutes.
Anti-Patterns
- No bare
@Processor(NAME): Always pass worker options object withdrainDelayandstalledInterval. - No bare
WorkerHostextension: Always extendBaseProcessorinstead to intercept and rate-limit worker errors. - No
registerQueuewithoutdefaultJobOptions: Omitting causes unbounded Redis memory growth. - No inline numbers: Use
bull-queue.constants.ts— never write10_000,60_000,50,20,3, or5_000directly. - No unguarded
queue.add(): Wrap in try-catch; persist DB state first. - No throws in throttler increment: Catch Redis errors; return fail-open record.
- No missing mock token: Provide
getQueueTokenmock whenredisEnabled = false. - No removing processor because cron exists: They serve different roles.
- No cloud Redis in dev: Use local Docker Redis.
References
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
- evals/evals.json
- references/patterns.md
FAQ
Что делает скилл nestjs-bullmq?
Implement BullMQ job workflows in NestJS. Use when building queue processors, redis-throttler, Upstash limits, idle polling, stalled jobs, and retention policies.
Как установить скилл nestjs-bullmq?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл nestjs-bullmq запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
AnthropicToolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
access
AnthropicManage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
configure
AnthropicSet up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
access
AnthropicManage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…