Skip to content
Multi-process nes backend, turn nes into a fully scalable solution
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
.travis.yml Upgrade to support hapi v17 May 31, 2018
multines.js add catches and make sure to wrap on util.promisify at the beginning … Jun 1, 2018
test.js Remove package-lock.json, update testing pattern. Jun 1, 2018

multines  Build Status

Multi-process nes backend, turn nes into a fully scalable solution.

multines connect multiple instances of Hapi and nes through an external pub/sub broker, currently only redis and mongodb are supported.

multines is powered by MQEmitter, MQEmitterRedis and MQEmitterMongodb.

Important note: this library needs nodejs 8 or greater.


npm i multines --save


See the examples folder.



  • [type] - 'redis' or 'mongodb', if nothing is specified it will use the in-memory MQEmitter
  • [mq] - an instance of MQEmitter, if you do not want to leverage the embedded constructor

The options object is passed through to MQEmitterRedis and MQEmitterMongodb, check their documentation for broker-specific config.

server.subscriptionFar(path, options)

Wrap nes server.subscription(path, options) adding the ability to receive messages from the MQEmitter-based broker.

The subscription supported is slightly different from nes, as it allows wildcards.

server.publishFar(path, message)

Publish a message to the MQEmitter-based broker.


This project was kindly sponsored by nearForm.



You can’t perform that action at this time.