worker-development

Create and manage BullMQ, Kafka, and cron background workers with retries.

601|129|Updated Dec 9, 2024
One-click install
npx skills add https://github.com/ChatbotXIO/ChatbotX --skill worker-development
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: worker-development
Source: https://github.com/ChatbotXIO/ChatbotX/tree/main/.agents/skills/worker-development
Command: npx skills add https://github.com/ChatbotXIO/ChatbotX --skill worker-development

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill removes the complexity of building reliable background processing in a large monorepo, so asynchronous work does not block user-facing applications.

Core Features & Use Cases

  • Queue and Worker Design: Define BullMQ queues, job types, and dedicated Node worker processes for domain-specific workloads.
  • Scheduled and Event-Driven Processing: Implement cron-style jobs, Kafka consumers, and repeatable queue tasks for automation and high-throughput flows.
  • Operational Guardrails: Apply deterministic job IDs, bootstrapping, logging, retries, and deduplication patterns to keep background work stable in production.

Quick Start

Ask the assistant to add a new worker for your domain, including its queue definition, worker entry point, build registration, and development script.

Frequently Asked Questions about worker-development

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up background workers for BullMQ queues in a monorepo?

Setting up background workers for BullMQ queues requires defining dedicated Node worker processes, job types, and Redis-backed queue configurations. You bootstrap the worker entry point, register the build, and add development scripts to process domain-specific jobs asynchronously.

What is the best way to prevent duplicate jobs in Redis-backed queues?

Preventing duplicate jobs in Redis-backed queues is achieved by applying deterministic job IDs during enqueueing. This deduplication pattern ensures repeatable queue tasks and scheduled cron workers process safely without executing the same asynchronous workload multiple times.

Can I use Kafka consumers alongside cron workers for scheduled tasks?

Yes, Kafka consumers can be used alongside cron workers for scheduled tasks. This approach combines event-driven processing for high-throughput flows with cron-style jobs for automation, all managed safely through dedicated background worker processes.

Why does my background job processing block user-facing applications?

Background job processing blocks user-facing applications when asynchronous work is not offloaded to dedicated workers. Moving heavy workloads to BullMQ queues or Kafka consumers with proper worker bootstrap prevents this blocking and keeps applications responsive.

How do you handle retries and logging for background workers?

Handling retries and logging for background workers involves applying operational guardrails during worker bootstrap. By configuring safe retry behaviors and structured logging alongside deterministic job IDs, background processing remains stable and observable in production environments.