Socket
Socket
Sign inDemoInstall

amqp-connection-manager

Package Overview
Dependencies
16
Maintainers
1
Versions
67
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 3.2.2 to 3.2.3

.github/dependabot.yml

2

.nyc_output/processinfo/index.json

@@ -1,1 +0,1 @@

{"processes":{"046ee5ef-e015-4357-a20c-3b3965863bdd":{"parent":null,"children":[]},"ef3a0a7f-3efd-4474-a800-38a9b92be3bb":{"parent":null,"children":[]}},"files":{"/home/runner/work/node-amqp-connection-manager/node-amqp-connection-manager/src/ChannelWrapper.js":["046ee5ef-e015-4357-a20c-3b3965863bdd","ef3a0a7f-3efd-4474-a800-38a9b92be3bb"],"/home/runner/work/node-amqp-connection-manager/node-amqp-connection-manager/src/helpers.js":["046ee5ef-e015-4357-a20c-3b3965863bdd","ef3a0a7f-3efd-4474-a800-38a9b92be3bb"],"/home/runner/work/node-amqp-connection-manager/node-amqp-connection-manager/src/AmqpConnectionManager.js":["046ee5ef-e015-4357-a20c-3b3965863bdd","ef3a0a7f-3efd-4474-a800-38a9b92be3bb"],"/home/runner/work/node-amqp-connection-manager/node-amqp-connection-manager/src/index.js":["046ee5ef-e015-4357-a20c-3b3965863bdd","ef3a0a7f-3efd-4474-a800-38a9b92be3bb"]},"externalIds":{}}
{"processes":{"bbf7abd4-c7a7-42fc-9403-67cb9716f5f2":{"parent":null,"children":[]},"e45aa186-8ebe-4305-ab01-6738ea760a73":{"parent":null,"children":[]}},"files":{"/home/runner/work/node-amqp-connection-manager/node-amqp-connection-manager/src/AmqpConnectionManager.js":["bbf7abd4-c7a7-42fc-9403-67cb9716f5f2","e45aa186-8ebe-4305-ab01-6738ea760a73"],"/home/runner/work/node-amqp-connection-manager/node-amqp-connection-manager/src/ChannelWrapper.js":["bbf7abd4-c7a7-42fc-9403-67cb9716f5f2","e45aa186-8ebe-4305-ab01-6738ea760a73"],"/home/runner/work/node-amqp-connection-manager/node-amqp-connection-manager/src/helpers.js":["bbf7abd4-c7a7-42fc-9403-67cb9716f5f2","e45aa186-8ebe-4305-ab01-6738ea760a73"],"/home/runner/work/node-amqp-connection-manager/node-amqp-connection-manager/src/index.js":["bbf7abd4-c7a7-42fc-9403-67cb9716f5f2","e45aa186-8ebe-4305-ab01-6738ea760a73"]},"externalIds":{}}

@@ -0,130 +1,120 @@

## [3.2.3](https://github.com/jwalton/node-amqp-connection-manager/compare/v3.2.2...v3.2.3) (2021-08-21)
### Bug Fixes
- fixed issue with publish ignoring 'drain' event ([e195d9b](https://github.com/jwalton/node-amqp-connection-manager/commit/e195d9bc29907de49eec5e09aea3bba0b894d965)), closes [#129](https://github.com/jwalton/node-amqp-connection-manager/issues/129)
## [3.2.2](https://github.com/jwalton/node-amqp-connection-manager/compare/v3.2.1...v3.2.2) (2021-02-09)
### Bug Fixes
* When messages are acked/nacked, make sure we remove the correct message from the sent messages queue. ([c662026](https://github.com/jwalton/node-amqp-connection-manager/commit/c662026bc287e684a0f43ce2de7a44b80a88e8ff)), closes [#142](https://github.com/jwalton/node-amqp-connection-manager/issues/142)
- When messages are acked/nacked, make sure we remove the correct message from the sent messages queue. ([c662026](https://github.com/jwalton/node-amqp-connection-manager/commit/c662026bc287e684a0f43ce2de7a44b80a88e8ff)), closes [#142](https://github.com/jwalton/node-amqp-connection-manager/issues/142)
## [3.2.1](https://github.com/jwalton/node-amqp-connection-manager/compare/v3.2.0...v3.2.1) (2020-09-12)
### Bug Fixes
* Push never resolves if error occured (courtesy @SSANSH). ([48a78f8](https://github.com/jwalton/node-amqp-connection-manager/commit/48a78f8de5d39002035b37f27fc3e0ce5015490c))
* **package:** resolve hanging retry connection timeout by introducing cancelable timeout ([e37dd1a](https://github.com/jwalton/node-amqp-connection-manager/commit/e37dd1a4e423012910d31ae8bcebf781cac6f3b5))
- Push never resolves if error occured (courtesy @SSANSH). ([48a78f8](https://github.com/jwalton/node-amqp-connection-manager/commit/48a78f8de5d39002035b37f27fc3e0ce5015490c))
- **package:** resolve hanging retry connection timeout by introducing cancelable timeout ([e37dd1a](https://github.com/jwalton/node-amqp-connection-manager/commit/e37dd1a4e423012910d31ae8bcebf781cac6f3b5))
# [3.2.0](https://github.com/jwalton/node-amqp-connection-manager/compare/v3.1.1...v3.2.0) (2020-01-20)
### Features
* add bindQueue and assertExchange on ChannelWrapper ([879e522](https://github.com/jwalton/node-amqp-connection-manager/commit/879e522))
- add bindQueue and assertExchange on ChannelWrapper ([879e522](https://github.com/jwalton/node-amqp-connection-manager/commit/879e522))
## [3.1.1](https://github.com/jwalton/node-amqp-connection-manager/compare/v3.1.0...v3.1.1) (2020-01-06)
### Bug Fixes
* typo ([6055b02](https://github.com/jwalton/node-amqp-connection-manager/commit/6055b02))
- typo ([6055b02](https://github.com/jwalton/node-amqp-connection-manager/commit/6055b02))
# [3.1.0](https://github.com/jwalton/node-amqp-connection-manager/compare/v3.0.0...v3.1.0) (2019-12-06)
### Features
* Allow using URL object to connect, same format as amqplib accepts. ([f046680](https://github.com/jwalton/node-amqp-connection-manager/commit/f046680))
- Allow using URL object to connect, same format as amqplib accepts. ([f046680](https://github.com/jwalton/node-amqp-connection-manager/commit/f046680))
# [3.0.0](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.3.3...v3.0.0) (2019-07-04)
### Continuous Integration
* Stop running tests for node 6 and node 8. ([164b882](https://github.com/jwalton/node-amqp-connection-manager/commit/164b882))
- Stop running tests for node 6 and node 8. ([164b882](https://github.com/jwalton/node-amqp-connection-manager/commit/164b882))
### BREAKING CHANGES
* Officially drop support for node 6 and node 8 (although they will probably still
work).
- Officially drop support for node 6 and node 8 (although they will probably still
work).
## [2.3.3](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.3.2...v2.3.3) (2019-06-25)
### Bug Fixes
* **package:** update promise-breaker to version 5.0.0 ([ed91042](https://github.com/jwalton/node-amqp-connection-manager/commit/ed91042))
- **package:** update promise-breaker to version 5.0.0 ([ed91042](https://github.com/jwalton/node-amqp-connection-manager/commit/ed91042))
## [2.3.2](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.3.1...v2.3.2) (2019-05-21)
### Bug Fixes
* Null delta to get semantic-release to pick up [#65](https://github.com/jwalton/node-amqp-connection-manager/issues/65). Fix [#84](https://github.com/jwalton/node-amqp-connection-manager/issues/84). ([9737135](https://github.com/jwalton/node-amqp-connection-manager/commit/9737135))
- Null delta to get semantic-release to pick up [#65](https://github.com/jwalton/node-amqp-connection-manager/issues/65). Fix [#84](https://github.com/jwalton/node-amqp-connection-manager/issues/84). ([9737135](https://github.com/jwalton/node-amqp-connection-manager/commit/9737135))
## [2.3.1](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.3.0...v2.3.1) (2019-04-01)
### Bug Fixes
* prevent too many connection attempts on error ([2760ce5](https://github.com/jwalton/node-amqp-connection-manager/commit/2760ce5)), closes [#77](https://github.com/jwalton/node-amqp-connection-manager/issues/77)
- prevent too many connection attempts on error ([2760ce5](https://github.com/jwalton/node-amqp-connection-manager/commit/2760ce5)), closes [#77](https://github.com/jwalton/node-amqp-connection-manager/issues/77)
# [2.3.0](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.2.0...v2.3.0) (2018-11-20)
### Features
* Add ChannelWrapper.ackAll() and ChannelWrapper.nackAll(). ([0246695](https://github.com/jwalton/node-amqp-connection-manager/commit/0246695)), closes [#60](https://github.com/jwalton/node-amqp-connection-manager/issues/60)
- Add ChannelWrapper.ackAll() and ChannelWrapper.nackAll(). ([0246695](https://github.com/jwalton/node-amqp-connection-manager/commit/0246695)), closes [#60](https://github.com/jwalton/node-amqp-connection-manager/issues/60)
# [2.2.0](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.1.2...v2.2.0) (2018-09-25)
### Features
* Set 'this' to be the channel wrapper in the setup function. ([551200f](https://github.com/jwalton/node-amqp-connection-manager/commit/551200f))
- Set 'this' to be the channel wrapper in the setup function. ([551200f](https://github.com/jwalton/node-amqp-connection-manager/commit/551200f))
## [2.1.2](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.1.1...v2.1.2) (2018-09-13)
### Bug Fixes
* Export a default object from root module. ([78893c9](https://github.com/jwalton/node-amqp-connection-manager/commit/78893c9)), closes [#51](https://github.com/jwalton/node-amqp-connection-manager/issues/51)
- Export a default object from root module. ([78893c9](https://github.com/jwalton/node-amqp-connection-manager/commit/78893c9)), closes [#51](https://github.com/jwalton/node-amqp-connection-manager/issues/51)
## [2.1.1](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.1.0...v2.1.1) (2018-09-05)
### Bug Fixes
* Remove reconnection listener when closing the connection manager. ([eeb6e2b](https://github.com/jwalton/node-amqp-connection-manager/commit/eeb6e2b))
- Remove reconnection listener when closing the connection manager. ([eeb6e2b](https://github.com/jwalton/node-amqp-connection-manager/commit/eeb6e2b))
# [2.1.0](https://github.com/jwalton/node-amqp-connection-manager/compare/v2.0.0...v2.1.0) (2018-08-09)
### Features
* Support for per URL connection options ([ec2d484](https://github.com/jwalton/node-amqp-connection-manager/commit/ec2d484)), closes [#29](https://github.com/jwalton/node-amqp-connection-manager/issues/29) [#34](https://github.com/jwalton/node-amqp-connection-manager/issues/34) [#44](https://github.com/jwalton/node-amqp-connection-manager/issues/44)
- Support for per URL connection options ([ec2d484](https://github.com/jwalton/node-amqp-connection-manager/commit/ec2d484)), closes [#29](https://github.com/jwalton/node-amqp-connection-manager/issues/29) [#34](https://github.com/jwalton/node-amqp-connection-manager/issues/34) [#44](https://github.com/jwalton/node-amqp-connection-manager/issues/44)
<a name="2.0.0"></a>
# [2.0.0](https://github.com/jwalton/node-amqp-connection-manager/compare/v1.4.2...v2.0.0) (2018-05-05)
### Code Refactoring
* Rewrite all source in javascript. ([377d01d](https://github.com/jwalton/node-amqp-connection-manager/commit/377d01d))
- Rewrite all source in javascript. ([377d01d](https://github.com/jwalton/node-amqp-connection-manager/commit/377d01d))
### BREAKING CHANGES
* Officially dropping support for node v4.x.x.
- Officially dropping support for node v4.x.x.
# 1.4.0
* Add 'blocked' and 'unblocked' events (#25).
- Add 'blocked' and 'unblocked' events (#25).
# 1.3.7
* Fix bug where we would stop sending messages if remote gracefully closes connection.
- Fix bug where we would stop sending messages if remote gracefully closes connection.
# 1.3.6
* Fix bug where ChannelWrapper would expect setup function to return a Promise
- Fix bug where ChannelWrapper would expect setup function to return a Promise
and not accept a callback if channel was already connected.

@@ -65,3 +65,3 @@ "use strict";

if (!urls && !options.findServers) {
throw new Error("Must supply either `urls` or `findServers`");
throw new Error('Must supply either `urls` or `findServers`');
}

@@ -162,3 +162,3 @@

if (typeof urlString === "object") {
if (typeof urlString === 'object') {
amqpUrl = Object.assign({}, url);

@@ -188,5 +188,3 @@

connection.on('unblocked', () => this.emit('unblocked'));
connection.on('error', () =>
/* err */
{// if this event was emitted, then the connection was already closed,
connection.on('error', () => {// if this event was emitted, then the connection was already closed,
// so no need to call #close here

@@ -193,0 +191,0 @@ // also, 'close' is emitted after 'error',

@@ -350,2 +350,3 @@ "use strict";

const encodedMessage = this._json ? new Buffer.from(JSON.stringify(message.content)) : message.content;
let result = true;

@@ -356,3 +357,3 @@ const sendPromise = (() => {

return new Promise(function (resolve, reject) {
const result = channel.publish(message.exchange, message.routingKey, encodedMessage, message.options, err => {
result = channel.publish(message.exchange, message.routingKey, encodedMessage, message.options, err => {
if (err) {

@@ -368,3 +369,3 @@ reject(err);

return new Promise(function (resolve, reject) {
const result = channel.sendToQueue(message.queue, encodedMessage, message.options, err => {
result = channel.sendToQueue(message.queue, encodedMessage, message.options, err => {
if (err) {

@@ -383,7 +384,10 @@ reject(err);

}
})(); // Send some more!
})();
if (result) {
this._publishQueuedMessages(workerNumber);
} else {
this._channel.once('drain', () => this._publishQueuedMessages(workerNumber));
}
this._publishQueuedMessages(workerNumber);
return sendPromise;

@@ -390,0 +394,0 @@ }).then(result => {

{
"name": "amqp-connection-manager",
"version": "3.2.2",
"description": "Auto-reconnect and round robin support for amqplib.",
"main": "lib/index.js",
"dependencies": {
"promise-breaker": "^5.0.0"
},
"peerDependencies": {
"amqplib": "*"
},
"devDependencies": {
"@babel/cli": "^7.11.6",
"@babel/core": "^7.11.6",
"@babel/preset-env": "^7.11.5",
"@babel/register": "^7.11.5",
"@jwalton/semantic-release-config": "^1.0.0",
"@semantic-release/changelog": "^5.0.1",
"@semantic-release/git": "^9.0.0",
"amqplib": "^0.6.0",
"babel-plugin-istanbul": "^6.0.0",
"chai": "^4.1.2",
"chai-as-promised": "^7.1.1",
"chai-string": "^1.1.2",
"coveralls": "^3.1.0",
"cross-env": "^7.0.2",
"eslint": "^7.8.1",
"eslint-config-benbria": "^4.0.3",
"eslint-plugin-import": "^2.22.0",
"eslint-plugin-promise": "^4.2.1",
"greenkeeper-lockfile": "^1.14.0",
"husky": "^5.0.9",
"istanbul": "^0.4.0",
"mocha": "^8.1.3",
"nyc": "^15.1.0",
"promise-tools": "^2.1.0",
"proxyquire": "^2.1.3",
"semantic-release": "^17.1.1",
"sinon": "^9.0.3"
},
"engines": {
"node": ">=6.0.0",
"npm": ">5.0.0"
},
"scripts": {
"prepare": "npm run build",
"prepublishOnly": "npm test",
"build": "babel -s -d lib src",
"clean": "rm -rf lib coverage",
"test": "npm run test:lint && npm run test:unittest",
"test:unittest": "cross-env NODE_ENV=test nyc mocha",
"test:lint": "eslint src test",
"precommit:unittest": "cross-env BABEL_DISABLE_CACHE=1 cross-env NODE_ENV=test nyc mocha --reporter progress",
"semantic-release": "semantic-release"
},
"husky": {
"hooks": {
"pre-commit": "npm run test:lint && npm run precommit:unittest"
}
},
"repository": {
"type": "git",
"url": "https://github.com/jwalton/node-amqp-connection-manager"
},
"keywords": [
"amqp",
"rabbitmq",
"cluster",
"amqplib"
],
"author": "Jason Walton <dev@lucid.thedreaming.org> (https://github.com/jwalton)",
"license": "MIT",
"bugs": {
"url": "https://github.com/jwalton/node-amqp-connection-manager/issues"
},
"homepage": "https://github.com/jwalton/node-amqp-connection-manager"
"name": "amqp-connection-manager",
"version": "3.2.3",
"description": "Auto-reconnect and round robin support for amqplib.",
"main": "lib/index.js",
"dependencies": {
"promise-breaker": "^5.0.0"
},
"peerDependencies": {
"amqplib": "*"
},
"devDependencies": {
"@babel/cli": "^7.11.6",
"@babel/core": "^7.11.6",
"@babel/preset-env": "^7.11.5",
"@babel/register": "^7.11.5",
"@jwalton/semantic-release-config": "^1.0.0",
"@semantic-release/changelog": "^5.0.1",
"@semantic-release/git": "^9.0.0",
"amqplib": "^0.8.0",
"babel-plugin-istanbul": "^6.0.0",
"chai": "^4.1.2",
"chai-as-promised": "^7.1.1",
"chai-string": "^1.1.2",
"coveralls": "^3.1.0",
"cross-env": "^7.0.2",
"eslint": "^7.8.1",
"eslint-config-benbria": "^4.0.3",
"eslint-plugin-import": "^2.22.0",
"eslint-plugin-promise": "^5.0.0",
"greenkeeper-lockfile": "^1.14.0",
"husky": "^7.0.1",
"istanbul": "^0.4.0",
"lint-staged": "^11.1.2",
"mocha": "^9.0.1",
"nyc": "^15.1.0",
"prettier": "^2.3.2",
"pretty-quick": "^3.1.1",
"promise-tools": "^2.1.0",
"proxyquire": "^2.1.3",
"semantic-release": "^17.1.1",
"sinon": "^11.0.0"
},
"engines": {
"node": ">=6.0.0",
"npm": ">5.0.0"
},
"scripts": {
"prepare": "husky install && npm run build",
"prepublishOnly": "npm test",
"build": "babel -s -d lib src",
"clean": "rm -rf lib coverage",
"test": "npm run test:lint && npm run test:unittest",
"test:unittest": "cross-env NODE_ENV=test nyc mocha",
"test:lint": "eslint src test",
"precommit:unittest": "cross-env BABEL_DISABLE_CACHE=1 cross-env NODE_ENV=test nyc mocha --reporter progress",
"semantic-release": "semantic-release"
},
"repository": {
"type": "git",
"url": "https://github.com/jwalton/node-amqp-connection-manager"
},
"lint-staged": {
"**/*.js": [
"eslint"
]
},
"keywords": [
"amqp",
"rabbitmq",
"cluster",
"amqplib"
],
"author": "Jason Walton <dev@lucid.thedreaming.org> (https://github.com/jwalton)",
"license": "MIT",
"bugs": {
"url": "https://github.com/jwalton/node-amqp-connection-manager/issues"
},
"homepage": "https://github.com/jwalton/node-amqp-connection-manager"
}

@@ -14,9 +14,11 @@ [![NPM version](https://badge.fury.io/js/amqp-connection-manager.svg)](https://npmjs.org/package/amqp-connection-manager)

This is a wrapper around [amqplib](http://www.squaremobius.net/amqp.node/) which provides automatic reconnects.
## Features
* Automatically reconnect when your amqplib broker dies in a fire.
* Automatically reconnect when your [amqplib](http://www.squaremobius.net/amqp.node/) broker dies in a fire.
* Round-robin connections between multiple brokers in a cluster.
* If messages are sent while the broker is unavailable, queues messages in memory until we reconnect.
* Supports both promises and callbacks (using [promise-breaker](https://github.com/jwalton/node-promise-breaker))
* Very un-opinionated library - a thin wrapper around amqplib.
* Very un-opinionated library - a thin wrapper around [amqplib](http://www.squaremobius.net/amqp.node/).

@@ -23,0 +25,0 @@ ## Installation

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc