limitd-client
Advanced tools
Comparing version 2.13.1 to 2.13.2
@@ -192,2 +192,8 @@ const url = require('url'); | ||
}).on('error', (err) => { | ||
//Ignore these type of errors since we are propagating "disconnect" | ||
//and reconnect-core will keep atempting to reconnect. | ||
if (err.code === 'ECONNRESET' || | ||
err.code === 'ECONNREFUSED') { | ||
return; | ||
} | ||
this.emit('error', err); | ||
@@ -194,0 +200,0 @@ }).on('reconnect', (n, delay) => { |
{ | ||
"name": "limitd-client", | ||
"version": "2.13.1", | ||
"version": "2.13.2", | ||
"description": "limitd client for node.js", | ||
@@ -21,3 +21,3 @@ "main": "index.js", | ||
"ms": "^1.0.0", | ||
"reconnect-net": "0.0.0", | ||
"reconnect-net": "^1.1.1", | ||
"retry": "^0.10.1", | ||
@@ -24,0 +24,0 @@ "tcp-client-failover": "^1.0.2" |
@@ -9,4 +9,6 @@ const LimitdClient = require('../'); | ||
const client = new LimitdClient({ protocol_version: 2 }); | ||
client.once('connect', () => server.close()); | ||
client.once('disconnect', () => done()); | ||
client.socket.reconnect = false; | ||
client | ||
.once('disconnect', () => done()) | ||
.once('connect', () => server.close()); | ||
}); | ||
@@ -13,0 +15,0 @@ }); |
@@ -7,3 +7,3 @@ const _ = require('lodash'); | ||
var PORT = 9231; | ||
var PORT = 15231; | ||
@@ -30,7 +30,8 @@ describe('limitd client failover', function() { | ||
}; | ||
client = new LimitdClient(config); | ||
client.once('connect', () => { | ||
setTimeout(done, 100); | ||
}); | ||
client | ||
.once('error', done) | ||
.once('connect', () => { | ||
setTimeout(done, 100); | ||
}); | ||
}); | ||
@@ -37,0 +38,0 @@ }); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
59476
21
1583
- Removedbackoff@2.3.0(transitive)
- Removedreconnect-core@0.0.1(transitive)
- Removedreconnect-net@0.0.0(transitive)
Updatedreconnect-net@^1.1.1