Re: EIdReadTimeout in TIdHTTP

Giganews Newsgroups
Subject: Re: EIdReadTimeout in TIdHTTP
Posted by:  Remy Lebeau (re…
Date: Tue, 4 Dec 2012

Fredrik wrote:

> We have a strange issue with read timeouts.

Are you using an up-to-date snapshot of Indy 10?

> We use a TROIndyHTTPChannel and sets the following timeout properties.
> FRemObjectsTransportChannel.IndyClient.ConnectTimeout := 5000;
> FRemObjectsTransportChannel.IndyClient.ReadTimeout := 60000;
> The IndyClient in TROIndyHTTPChannel is a TIdHTTP object.

> When we then call a function in the interface we can get a
> EIdReadTimeout after 5-7s.

What does the call stack look like when the exception is raised?  TIdHTTP
should definately be respecting the 60s timeout you assigned.  Is the exception
actually reaching your code, or is TIdHTTP handling it internally?  If the
latter, then don't worry about it.  You would only see it when running inside
a debugger.

I will comment that there is a 5s timeout used internally by HTTP only when
handling 3xx replies.  Perhaps that is the timeout you are encountering?
TIdHTTP should not be raising an exception into your code if that timeout
elapses, though.

Remy Lebeau (Indy Team)


In response to

EIdReadTimeout in TIdHTTP posted by Fredrik Sandedal on Tue, 4 Dec 2012