A read timeout (or response timeout) is a limit on how long a client waits for data after a connection is already open. It can apply to the first byte of the response or to the gap between chunks, depending on the library.
Why it matters
The server is reachable but too slow, hung, or stuck behind a long query. Without a read timeout, a client can wait forever on a dead connection, and threads or workers pile up until the application stops responding. With one, you fail fast and can retry or fall back.
Example
$ curl -sS --max-time 10 https://example.com/report
curl: (28) Operation timed out after 10001 milliseconds with 0 bytes received
Zero bytes received after a good connection indicates a slow or stuck application. Then look at:
- Slow database queries or locks.
- A saturated worker pool (see saturation).
- A reverse proxy with its own shorter limit, such as nginx
proxy_read_timeout(default 60 seconds), which returns 504 when exceeded.
Set client timeouts a bit below proxy timeouts so the caller sees a clean error.
Common mistakes
- Using one global timeout for fast health calls and slow report downloads.
- Relying on default timeouts, which in some libraries are infinite.
- Raising the timeout to hide a slow query instead of fixing it.
Related
Get notified when this term updates
Plus occasional practical tips on uptime and monitoring, nothing else. Unsubscribe anytime.
यह पेज सामान्य जानकारी है, जिसे हमारी संपादकीय टीम ने लिखा है और दस्तावेज़ीकरण बदलने पर अपडेट किया जाता है। सर्वर और प्रदाता अलग-अलग होते हैं, इसलिए बदलाव पहले सुरक्षित तरीके से जाँचें। देखें: संपादकीय नीति और अस्वीकरण.