From ec802899c3020417b10a627c43c54dac167449cb Mon Sep 17 00:00:00 2001 From: roks0n Date: Tue, 6 Aug 2019 22:20:00 +0200 Subject: [PATCH] add changelog, reduce socketCluster timeout to 2s --- CHANGELOG.md | 6 ++++++ package.json | 2 +- src/peer.js | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..892e34b --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,6 @@ +# Changelog + + +## [1.2.10] - 2019-08-06 + +- Lower socketcluster client timeout from 10s to 2s diff --git a/package.json b/package.json index d4df3f3..de80471 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@deadlock-delegate/crawler", - "version": "1.2.9", + "version": "1.2.10", "description": "Crawler scans the ARK network to get information about the peers in the network.", "main": "src/crawler.js", "scripts": { diff --git a/src/peer.js b/src/peer.js index e9d7b21..4a264ff 100644 --- a/src/peer.js +++ b/src/peer.js @@ -10,7 +10,7 @@ class Peers { if (connection) { return connection } - connection = SocketClient.create({ hostname: ip, port }) + connection = SocketClient.create({ hostname: ip, port, connectTimeout: 2000 }) connection.on('error', (err) => { console.error(err) connection.destroy()