diff options
author | Ryan Dahl <ry@tinyclouds.org> | 2010-10-23 11:59:32 -0700 |
---|---|---|
committer | Ryan Dahl <ry@tinyclouds.org> | 2010-10-23 12:28:20 -0700 |
commit | 0ac2ef924f2564ab967be22c7b4ae18c20ff4fc2 (patch) | |
tree | 9229f56a2b1f11553a3c28a69ef5ab21097e1ef4 /TODO | |
parent | 9bf2975f78ce097c82a720bdda82810c1188a8ef (diff) | |
download | node-0ac2ef924f2564ab967be22c7b4ae18c20ff4fc2.tar.gz |
Do not spin on aceept() with EMFILE
When a server hit EMFILE it would continue to try to accept new connections
from the queue. This patch introduces a timeout of one second where it will
stop trying to accept new files. After the second is over it tries again.
This is a rather serious bug that has been effecting many highly concurrent
programs. It was introduced in 4593c0, version v0.2.0.
TODO: A test for this situation. Currently I test it like this
termA% cd projects/node
termA% ulimit -n 256
termA% ./node benchmark/idle_server.js
termB% cd projects/node
termB% ./node benchmark/idle_clients.js
And watch how the server process behaves.
Diffstat (limited to 'TODO')
-rw-r--r-- | TODO | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -25,3 +25,4 @@ based on size but rather read until EOF into a chain of buffers, then concat them together. - process object should be defined in src/node.js not in c++ +- Test for EMFILE accept spin bug. |