Skip to content

Commit

Permalink
Keep-alive with wallet
Browse files Browse the repository at this point in the history
  • Loading branch information
xcps authored and r4sas committed Aug 24, 2019
1 parent 4ad36ab commit 548ca59
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bin/syncBlockchain.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ var rpcConfig = require('../config/config')['rpc'];

const {username, password, hostname, port} = rpcConfig;

const keepAliveAgent = new http.Agent({ keepAlive: true });


let sync_sql = '',
coolstrs = [];

Expand All @@ -18,6 +21,7 @@ function MakeRPCRequest(postData) {
auth: `${username}:${password}`,
path: '/',
method: 'POST',
agent: keepAliveAgent,
headers: {
'Content-Type': 'application/x-www-form-urlencoded',
'Content-Length': Buffer.byteLength(postData)
Expand Down

0 comments on commit 548ca59

Please sign in to comment.