Joined January 2015
·

Alexey Shevchenko

Ukraine
·
·

Posted to Using xargs and positional args over 1 year ago

Thanks!

So if you interested in, the problem was that httpS server doesn't inherit sockets timeout logic from http server.

There is a patch merged since Apr 2013:
https://github.com/joyent/node/issues/5361

But it still doesn't merged to stable 0.10 branch.

The solutions:
- avoid https usage, use some proxy server (nginx)
- custom timeout handle
- use node version higher than 0.10

Related serverfault topic:
http://serverfault.com/questions/660248/nodejs-server-doesnt-close-tcp-connections

@lperrin

Thanks for the response. But even if somewhere is a callback that didn't called, there is 2 minutes timeout:
http://nodejs.org/api/all.html#all_server_settimeout_msecs_callback

But the connections that I am facing, looks that they are living much longer.

Did you find what was the case of your leaking sockets?

Currently I experience similar behavior - during the time I have living tcp connections that didn't close for unknown reason.

So they stacking and makes server to drop connections after about a day. Node.js cluster restart is helps but it isn't a solution.

Achievements
1 Karma
0 Total ProTip Views