lpereira / lwan

Experimental, scalable, high performance HTTP server
https://lwan.ws
GNU General Public License v2.0
5.92k stars 549 forks source link

If a connection is open but no request is made, it will continue to use resources until lwan is shut down #35

Closed lpereira closed 10 years ago

fiorix commented 10 years ago

Make read and write time outs configurable.

On Jan 8, 2014, at 6:25 AM, "Leandro A. F. Pereira" notifications@github.com wrote:

— Reply to this email directly or view it on GitHub.

lpereira commented 10 years ago

Since epoll is used in edge-triggered mode, if there's no socket activity, it'll block forever (even with a timeout value > 0). Haven't found any way around this that's not costly.

The timeout value is already configurable (I use the keep-alive timeout for connection timeouts).

fiorix commented 10 years ago

Still worth investigating alternative solutions even if they're costly. Otherwise the server is too vulnerable to running out of sockets due to idle connections.

On Jan 8, 2014, at 10:37 AM, Leandro A. F. Pereira notifications@github.com wrote:

Since epoll is used in edge-triggered mode, if there's no socket activity, it'll block forever (even with a timeout value > 0). Haven't found any way around this that's not costly.

— Reply to this email directly or view it on GitHub.