1.1.3 • Published 4 years ago

rabbit-lib-node v1.1.3

Weekly downloads
-
License
ISC
Repository
-
Last release
4 years ago

Rabbit Lib Node

This library abstracts the amqplib layers and can work with a cleaner code.

Exemplo Methods

  • consumer
  • publisher
  • rpcRabbit
  • rpcPublisher

How to Install

npm install --save rabbit-lib-node

Usage

This session will show you how to use the library:

diagram

How to import
const Rabbit = require('rabbit-lib-node');
Consumer Example
new Rabbit({ callback: (msg) => {
	console.log(msg)
}, address: 'amqp://guest:guest@localhost:5672',
q:  'queue.topic' }).consumer()
Publisher Example
new Rabbit({ 
	address: 'amqp://guest:guest@localhost:5672',
	q: 'queue.topic' }).publisher({...})
RPC Consumer Example
new Rabbit({ callback: (msg) => {
	console.log(msg)
}, address: 'amqp://guest:guest@localhost:5672',
	q: 'queue.topic' }).rpcRabbit()
RPC Publisher Example
new Rabbit({ callback: (msg) => {
	console.log(msg)
}, address: 'amqp://guest:guest@localhost:5672',
	q: 'queue.topic' }).rpcPublisher({...})
1.1.3

4 years ago

1.1.2

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago