cluster-client
Advanced tools
Comparing version 2.1.0 to 2.1.1
2.1.1 / 2018-06-12 | ||
================== | ||
**fixes** | ||
* [[`9fe3849`](http://github.com/node-modules/cluster-client/commit/9fe38494d41afca76491c78cf54b2717508f94b9)] - fix: follower should not retry register channel if socket already disconnected (#43) (zōng yǔ <<gxcsoccer@users.noreply.github.com>>) | ||
2.1.0 / 2018-03-26 | ||
@@ -3,0 +9,0 @@ ================== |
@@ -218,6 +218,11 @@ 'use strict'; | ||
if (err) { | ||
err.message = `register to channel: ${this.options.name} failed, will retry after 3s, ${err.message}`; | ||
this.logger.warn(err); | ||
// if exception, retry after 3s | ||
setTimeout(() => this._registerChannel(), 3000); | ||
// if socket alive, do retry | ||
if (this._socket) { | ||
err.message = `register to channel: ${this.options.name} failed, will retry after 3s, ${err.message}`; | ||
this.logger.warn(err); | ||
// if exception, retry after 3s | ||
setTimeout(() => this._registerChannel(), 3000); | ||
} else { | ||
this.ready(err); | ||
} | ||
return; | ||
@@ -224,0 +229,0 @@ } |
{ | ||
"name": "cluster-client", | ||
"version": "2.1.0", | ||
"version": "2.1.1", | ||
"description": "Sharing Connection among Multi-Process Nodejs", | ||
@@ -13,7 +13,7 @@ "main": "./index.js", | ||
"lint": "eslint . --ext .js", | ||
"cov": "egg-bin cov", | ||
"cov": "TEST_TIMEOUT=20000 egg-bin cov", | ||
"test": "npm run lint && npm run test-local", | ||
"test-local": "egg-bin test", | ||
"pkgfiles": "egg-bin pkgfiles --check", | ||
"ci": "npm run autod --check && npm run pkgfiles && npm run lint && npm run cov", | ||
"ci": "npm run autod -- --check && npm run pkgfiles && npm run lint && npm run cov", | ||
"contributors": "contributors -f plain -o AUTHORS" | ||
@@ -70,4 +70,4 @@ }, | ||
"ci": { | ||
"version": "8, 9" | ||
"version": "8, 10" | ||
} | ||
} |
70411
1800