Skip to content

Commit

Permalink
Tweak advanced timeouts docs (#1420)
Browse files Browse the repository at this point in the history
  • Loading branch information
florimondmanca authored Dec 8, 2020
1 parent 7ea6019 commit 584a405
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions docs/advanced.md
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,7 @@ There are four different types of timeouts that may occur. These are **connect**
**read**, **write**, and **pool** timeouts.

* The **connect** timeout specifies the maximum amount of time to wait until
a connection to the requested host is established. If HTTPX is unable to connect
a socket connection to the requested host is established. If HTTPX is unable to connect
within this time frame, a `ConnectTimeout` exception is raised.
* The **read** timeout specifies the maximum duration to wait for a chunk of
data to be received (for example, a chunk of the response body). If HTTPX is
Expand All @@ -645,7 +645,7 @@ to send data within this time frame, a `WriteTimeout` exception is raised.
a connection from the connection pool. If HTTPX is unable to acquire a connection
within this time frame, a `PoolTimeout` exception is raised. A related
configuration here is the maximum number of allowable connections in the
connection pool, which is configured by the `pool_limits`.
connection pool, which is configured by the `limits` argument.

You can configure the timeout behavior for any of these values...

Expand All @@ -667,7 +667,6 @@ allow. (Defaults 10)
- `max_connections`, maximum number of allowable connections, or` None` for no limits.
(Default 100)


```python
limits = httpx.Limits(max_keepalive_connections=5, max_connections=10)
client = httpx.Client(limits=limits)
Expand Down

0 comments on commit 584a405

Please sign in to comment.