Implement robust batch processing systems with job queues, schedulers, background tasks, and distributed workers. Use when processing large datasets, scheduled tasks, async operations, or resource-intensive computations.
Implement scalable batch processing systems for handling large-scale data processing, scheduled tasks, and async operations efficiently.
Minimal working example:
import Queue from "bull";
import { v4 as uuidv4 } from "uuid";
interface JobData {
id: string;
type: string;
payload: any;
userId?: string;
metadata?: Record<string, any>;
}
interface JobResult {
success: boolean;
data?: any;
error?: string;
processedAt: number;
duration: number;
}
class BatchProcessor {
private queue: Queue.Queue<JobData>;
private resultQueue: Queue.Queue<JobResult>;
constructor(redisUrl: string) {
// Main processing queue
// ... (see reference guides for full implementation)
Detailed implementations in the references/ directory:
| Guide | Contents | |---|---| | Bull Queue (Node.js) | Bull Queue (Node.js) | | Celery-Style Worker (Python) | Celery-Style Worker (Python) | | Cron Job Scheduler | Cron Job Scheduler |
Copy a source-pinned command for your client. You run it yourself.
Destination: .claude/skills/batch-processing-jobs · pinned to the source commit
git clone https://github.com/aj-geddes/useful-ai-prompts.git
cd useful-ai-prompts
git checkout 3f5182cfd739fc113f4af5244a1cf342ad7f7911
mkdir -p ".claude/skills/batch-processing-jobs"
cp -r "skills/batch-processing-jobs" ".claude/skills/batch-processing-jobs"Review the source before running. This copies files into your project; it is not a one-click install and does not verify runtime safety.
Scanner static-checks@0.1.0 · commit 3f5182cfd739. Static checks cannot prove runtime safety – review the source and the exact diff before installing. How checks work.
No static rules matched. This is not a safety guarantee.