Skip to content


Subversion checkout URL

You can clone with
Download ZIP


HTTP polling broken with keep alive and GET requests #495

BonsaiDen opened this Issue · 2 comments

3 participants


Tested on latest master:

Start this:

var sys = require('sys'),
http = require('http');
http.createServer(function (req, res) {
    console.log(req.headers, req.httpVersion);
    res.writeHead(200, {'Content-Type': 'text/plain', 'Connection': 'Close'});
    res.write(new Array(285).join('test'));
    function send(){
        setTimeout(send, 1000);

Now open the page in a Browser, works, now open it a second time, doesn't load.

Opera 11 loads, but displays the exact same page twice.

Now open another page but append something to the url, works.

Using curl etc. works too, so I suspect keep-alive to be broken somewhere, since curl doesn't set the header.

So the browsers reuse the connection but Node fails when one tries to do a simple polling example.

Breaks examples from here (and I suspect some other stuff too):

Note: Doing a POST request works, since there's no connection re-use on that one.

Found via:


Can't reproduce with HEAD. Suggest closing.


Also I cannot reproduce with v0.4.12. Closing.

@koichik koichik closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.