| Shea Martin 2004-06-30, 6:02 pm |
| Nick Landsberg wrote:
> Shea Martin wrote:
>
>
>
>
> Hmmm... 50 requests per minute.
>
> If the "holding time" of this socket averaged 5 seconds,
> then, during any given average period of time, you
> would be holding 250 sockets open.
>
> If the clients start to time out and *all* hold the
> socket open for 10 seconds, you would need 500
> file descriptors to handle that situation.
>
> (N (number of sockets) = Arrival Rate of requests
> * Holding Time of socket).
>
> If you can't increase the fd's per process, reduce the
> timeout to 5 seconds rather than 10. 5 will almost
> guarantee you safety, unless the the holding time
> of a valid request is substantially longer than
> the timeout time. In this case you have to do
> complex arithmetic regarding stuff such as Erlang
> blocking factors.
>
The average length of a request is much less than a second. I think that main
problem is leaked file descriptors.
But I am going to change the close-wait time anyway.
~S
|