mirror of
https://github.com/nodejs/node.git
synced 2026-11-24 21:50:36 -05:00
http: destroy sockets after keepAliveTimeout
Implement server.keepAliveTimeout in addition to server.timeout to prevent temporary socket/memory leaking in keep-alive mode. PR-URL: https://github.com/nodejs/node/pull/2534 Author: Timur Shemsedinov <timur.shemsedinov@gmail.com> Author: Alexey Orlenko <eaglexrlnk@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
This commit is contained in:
1 parent
d82f8c4c35
commit
f23b3b6bad
6 files changed
+249
-7
No files matched your search
+1
-1
@@ -37,7 +37,7 @@ function Server(opts, requestListener) {
|
||||
});
|
||||
|
||||
this.timeout = 2 * 60 * 1000;
|
||||
|
||||
this.keepAliveTimeout = 5000;
|
||||
this.headersTimeout = 40 * 1000; // 40 seconds
|
||||
}
|
||||
inherits(Server, tls.Server);
|
||||
|
||||
Reference in new issue
Block a user