Closed
Description
There are many different timeout strategies for waiting a response from client:
- uber timeout for total elapsed seconds
- timeout for waiting for available connection from a pool
- connection timeout for waiting a response from a new connection to server
- timeout for getting HTTP headers from response
- timeout for every HTTP body chunk read
- maybe you can add your case
As the solution I propose collapsing all timeouts into the single timeout class.
E.g. Timeout.after(30) is an uber timeout, Timeout.await_pool(5) is a timeout for waiting for connection pool. Timeout.after(30).await_pool(5) composes both.
Do you like the idea? Objections?