Registry / messaging / engined-queue

engined-queue

JSON →
library0.0.7jsnpmunverified

engined-queue is a queue agent service for the engined framework, built on top of engined-amqp. Version 0.0.7 is the latest stable release. It provides a simple consumer pattern for AMQP message queues with configurable exchanges and routing. Compared to raw AMQP libraries, it integrates tightly with engined's service manager and lifecycle.

npm install engined-queue
INSTALL
IMPORT
SIG · ENGINED-QUEUE
E
engined-queue
messagingjavascriptv0.0.7
harness data pending
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.

QueueService
const { QueueService } = require('engined-queue')
import { QueueService } from 'engined-queue'
Package is CommonJS-only; no ESM exports.
Consumer
const { Consumer } = require('engined-queue')
const Consumer = require('engined-queue').Consumer
Named export; default import is not available.
engined-queue
const enginedQueue = require('engined-queue')
import enginedQueue from 'engined-queue'
CommonJS require() is the only supported import style.

Sets up an engined manager with AMQP service, queue service, and a consumer, then starts all services.

const { Manager } = require('engined'); const AMQPService = require('engined-amqp'); const { QueueService, Consumer } = require('engined-queue'); const main = async () => { const manager = new Manager({ verbose: true }); manager.add('AMQP', AMQPService); manager.add('Queue', QueueService({ uri: process.env.AMQP_URI ?? 'amqp://localhost/myvhost' })); const MyConsumer = class extends Consumer({ exchangeName: 'myexchange', exchangeType: 'topic', targetQueue: 'myqueue', routingRules: 'black.*' }) { consume(routingKey, msg) { console.log('Received:', routingKey, msg); return true; } }; manager.add('MyConsumer', MyConsumer); await manager.startAll(); }; main().catch(console.error);
Debug
Known issues
breakingThe package requires engined-amqp to be installed and added as a service before the queue service.
fix
npm install engined-amqp and add 'AMQP' service before 'Queue' in code.
affects: >=0.0.0
deprecatedNo deprecation warnings known for current version.
fix
N/A
affects: 0.0.7
gotchaThe Consumer class must be instantiated via a call to Consumer({...}) which returns a class, not directly extended.
fix
Use const MyConsumer = class extends Consumer({...}) { ... };
affects: >=0.0.0
Errors
Common errors & fixes
Cannot find module 'engined-amqp'
engined-amqp is a peer dependency and must be installed separately.
fix
Run: npm install engined-amqp
Consumer is not a constructor
Consumer is a function that returns a class, not a class itself.
fix
Use: class MyConsumer extends Consumer({...}) { ... } or const MyConsumer = class extends Consumer({...}) { ... };
Cannot read property 'URI' of undefined
The QueueService expects a URI option but received undefined.
fix
Pass a valid URI: QueueService({ uri: 'amqp://localhost/myvhost' })
Upgrade
Version history
0.0.7latest on npm
Audit
Dependencies
engined-amqprequiredThis package is built on engined-amqp and requires it at runtime.
Agent activity
26 hits · last 30 days
node
24
Amazon
1
OpenAI (training)
1
Resources
engined-queue — npm install engined-queue · libregistry