Registry / database / oxen-queue

oxen-queue

JSON →
library0.1.12jsnpmunverified

oxen-queue v0.1.12 is a resilient worker queue backed by MySQL, designed for high-throughput job processing with features like persistence, priority, deduplication, concurrency, delayed jobs, and multi-process/server support. It is ideal for teams already running MySQL who need to process millions of jobs per day with SQL-queryable queues. Unlike alternatives like Bull or Kue, Oxen prioritizes throughput over low latency and handles dropped connections gracefully. It requires Node >=7 and a MySQL instance. Last release appears stable but low activity suggests maintenance mode.

databasedevops
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Package uses CommonJS only; ESM import will fail.

const Oxen = require('oxen-queue')

Default export is the constructor; named export does not exist. Use default import.

const { Oxen } = require('oxen-queue')

Only constructor pattern; no static factory methods.

new Oxen({ job_type: 'myqueue', mysql_config: {...} })

Initializes Oxen queue, creates required MySQL table, adds a job, and processes jobs with a worker function.

const Oxen = require('oxen-queue'); async function main() { const ox = new Oxen({ mysql_config: { user: 'root', password: process.env.MYSQL_PASSWORD ?? 'password', host: 'localhost', database: 'test' }, job_type: 'example_queue' }); // Create table once await ox.createTable(); // Add a job await ox.addJob({ key: 'job1', priority: 10, payload: { task: 'send_email' } }); // Process jobs ox.process(async (job) => { console.log('Processing:', job.id, job.payload); // Do work return { status: 'done' }; }); // Start processing ox.start(); } main().catch(console.error);
Debug
Known footguns
gotchaRequires Node >=7.0.0; older engines not supported.
gotchaQueue table must be created explicitly via createTable() before use.
breakingDefault exports only; named imports will fail.
deprecatedPackage is in maintenance mode with no recent updates.
Upgrade
Version history

Breaking-change detection hasn't run for this library yet.

Audit
Security & dependencies

CVE tracking and dependency tree are planned for a later release.

Agent activity
0 hits · last 30 days

No traffic data recorded yet.

Resources