falso-amqp
v0.0.13
Published
Falso AMQP
Downloads
19
Readme
falso-amqp
Falso AMQP - Node.js amqp-like server & client library
Falso AMQP is a AMQP-like server for Node.js. It client library is designed to be used exactly like amqplib with rabbitmq.
Support us
History
I was working with microservices in Node JS. The MS nodes were connected using RabbitMQ. My life was happy, until I've tried to deploy my project to azure. That was when I realize that the thing is was not so easy.
In order to use AMQP on Azure, I had two options:
- Set up a virtual machine, and a Rabbit MQ server inside.
- Use the AMQP service, provided by azure (you really have to control your messages exchange, otherwise it will be very expensive).
I just wanted a simpler think: deploy my microservices into an "app service" resource. Just that!
So, I decided to implement a AMQP-Like NodeJS Server and Client (library).
Getting started
You have two ways to implement the server.
Server (outside your project)
- Install falso-amqp globally
npm i falso-amqp -g
- Run it falso-amqp
Server (inside your project)
- Install falso-amqp
npm i falso-amqp --save
- Require
const runServer = require("falso-amqp");
runServer();
Client Library
npm i falso-amqp-client --save
The objetive of the Client library is to be compatible with Rabbit MQ.
Compatibility
Features based on amqplib channel api
| Function | Status | |----------------------------------|------------| |connect | OK | |ChannelModel and CallbackModel| | |connection.close | OK | |events | | |connection.createChannel | OK | |connection.createConfirmChannel | | |Channel | | |channel.close | | |events | | |channel.assertQueue | OK | |channel.checkQueue | | |channel.deleteQueue | | |channel.purgeQueue | | |channel.bindQueue | OK | |channel.unbindQueue | | |channel.assertExchange | OK | |channel.checkExchange | | |channel.deleteExchange | | |channel.bindExchange | | |channel.unbindExchange | | |channel.publish | OK | |channel.sendToQueue | OK | |channel.consume | OK | |channel.cancel | | |channel.get | | |channel.ack |In progress | |channel.ackAll | | |channel.nack |In progress | |channel.nackAll | | |channel.reject | | |channel.prefetch |In progress | |channel.recover | | |ConfirmChannel | | |confirmChannel.publish | | |confirmChannel.sendToQueue | | |confirmChannel.waitForConfirms | |