Created
November 7, 2018 03:17
-
-
Save gsquaredxc/df4ebd8a452028d8bfa5636e7f4ae298 to your computer and use it in GitHub Desktop.
problem
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var myAgent = new http.Agent({ | |
keepAlive: true, | |
maxSockets: 1, | |
keepAliveMsecs: 3000 | |
}); | |
request.post({url:'http://website.com/something', agent: myAgent , form: {key:'value',other:'value'}}, function(err,res,body){ /* ... */ }); | |
request.post({url:'http://website.com/something/else', agent: myAgent , form: {test:'value',otherkey:'value'}}, function(err,res,body){ /* ... */ }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment