Messages in this thread | | | Date | Tue, 21 Oct 2008 07:12:53 +0200 | From | Willy Tarreau <> | Subject | Re: poll() blocked / packets not received ? |
| |
On Mon, Oct 20, 2008 at 07:24:14PM +0200, Nicolas Cannasse wrote: > For (1) I can't add the timeout since I have no way to differentiate > between a lost connection and a request that takes time to execute.
Not only you can, but you *must*. Any service assuming infinite timeout is deemed to fail. If you know that one request can take as long as one minute for instance, then use a 2 minutes timeout. The day all requests will be automatically cleaned up because of a failed firewall between client and server, you'll be happy not to have to come there and restart the service to flush them.
There's a huge difference between using a very large timeout and none at all.
Willy
| |