HttpReaderPolicy
How long the HTTP reader, KtorMediaIo, waits for a server, and how it recovers when a connection drops.
The reader enforces these limits itself, with coroutine timeouts, so they hold with every Ktor engine and with a client that the application supplies. A wait that passes its limit fails with KtorMediaIoException, and during a read that failure makes the reader reconnect.
Constructors
Properties
The longest wait for the connection and the response headers of one request. A seek sends a new request, so this limits a seek too.
The wait before the first reconnect of a read. Each later wait is twice as long.
The longest wait between two reconnects.
How many times one read may reconnect after a failure, a read timeout or a response that ended early. Each reconnect is a Range request at the byte the reader reached. Zero turns recovery off. The count belongs to one read, so a connection that drops now and then never uses it up.
The longest wait for the next bytes of a response that has started.