http - Limit for concurrent connections to the same host in Node.js -


why code (or similar)

var http = require('http'); var async = require('async');  async.forever(function(next) {     http.get('http://google.com', function(res) {         next();     }); }); 

executing 5 times latest released node (0.10.28)?

by default, node sends http requests connection: keep-alive header set, connection not closed after 1 request. , default maximum number of concurrent connections same server:port set 5. controlled http.globalagent.maxsockets property.

it's mentioned in documentation it's hard find if don't know or don't read through docs. also, these classes being rewritten , next releases have different behaviour.


Comments

Popular posts from this blog

how to proxy from https to http with lighttpd -

android - Automated my builds -

python - Flask migration error -