https://github.com/workable/eip-rabbit
Rabbitmq Adapter for the eip module. It supports an aggregator Timer using rabbitmq queues.
https://github.com/workable/eip-rabbit
Last synced: 11 months ago
JSON representation
Rabbitmq Adapter for the eip module. It supports an aggregator Timer using rabbitmq queues.
- Host: GitHub
- URL: https://github.com/workable/eip-rabbit
- Owner: Workable
- Created: 2017-03-10T15:58:45.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2023-10-27T14:45:10.000Z (over 2 years ago)
- Last Synced: 2025-04-19T17:36:46.861Z (11 months ago)
- Language: TypeScript
- Size: 454 KB
- Stars: 1
- Watchers: 19
- Forks: 4
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# eip-rabbit
Enterprise Integration Patterns for javascript rabbitmq adapter.
Create a Timer for the eip aggregator that uses rabbitmq to implement the timeout.
## Installation
```
npm install --save eip-rabbit
```
## Usage
```javascript
const eip = require('eip');
const { Rabbit } = require('rabbit-queue');
const rabbit = new Rabbit('amqp://localhost', { scheduledPublish: true }); // scheduledPublish must be enabled
const { Timer } = require('eip-rabbit');
const timer = new Timer([1000, 5000], rabbit, 'timer') // delays in ms
const aggregator = new eip.Route().aggregate({ timer });
```
## License
MIT