A lightweight, type-safe MySQL-based job queue for Node.js (v0.1.5). Provides a simple API to enqueue and process jobs with retries, concurrency control, polling, and timeouts. Uses Zod for runtime schema validation and ships TypeScript definitions. Contrasts with Redis-backed queues like Bull by relying on MySQL, making it suitable for projects already using MySQL and wanting minimal dependencies. Release cadence is low, as it is a young package.
npm install mysql-queueNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Connects to MySQL, creates a queue, enqueues a job, and starts a runner with Zod validation and log handlers.
Use the async connect() function provided by mysql-queue to obtain the db object.
Ensure the Runner is set up with the correct pollIntervalMs for your desired polling schedule.
Check the library's issue tracker for updates; consider implementing cleanup manually.
Update code to use the new connect() API and the returned db object.
Set timeoutSecs appropriately for your expected job durations.
Run 'npm install mysql-queue' and ensure your project's package.json includes it.
Use the db object returned from await connect(uri).
Ensure the enqueued data matches the Zod schema defined for the queue.