A job queue for Node.js based on PostgreSQL, allowing you to define job handlers and process jobs using a CLI tool. The package is at version 0.3.3, with infrequent releases. It supports custom log, error, and shutdown handlers but has limited documentation. It differs from alternatives like Bull or Bee by using PostgreSQL as the backing store, which may be beneficial for teams already using PostgreSQL.
npm install pg-job-queueNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Creates a job queue instance, adds a job, defines a handler module, and runs the CLI processing loop.
Ensure job type uses dots to match nested handler path.
Use node_modules/pg-job-queue/bin/process-job-queue or add a script in package.json.
Use require() instead of import.
Ensure every handler calls job.finish() (or returns promise that resolves after finish).
Provide a valid connection string like postgres://user:password@host/db
Run npm install pg-job-queue
Use const jobqueue = require('pg-job-queue');Export a nested object matching the dotted job type; e.g., exports.sendmail.welcome