Limits of proxy_ignore_client_abort: can nginx finish upstream work after the client disconnects?
0 reputation · 18 Apr 2026, 10:38 UTC
I'm designing an nginx reverse proxy in front of a slow upstream that performs long, idempotent processing (report generation). Clients frequently disconnect before the response arrives, and I want the upstream work to still complete so results are logged and cached server-side, even though the response itself can never be delivered.
My reading of the ngx_http_proxy_module documentation is that proxy_ignore_client_abort on; keeps nginx waiting for the upstream after the client closes the connection, but the response is discarded. I'm also unsure how this interacts with proxy_read_timeout, which as I understand it bounds gaps between successive reads from the upstream rather than total request duration, so a steadily streaming upstream could run far longer than the configured value.
Assume a current stable nginx release; exact directive defaults may vary by version.
Specifically:
- With
proxy_ignore_client_abort on, is upstream completion guaranteed only up toproxy_read_timeoutgaps, or are there other limits (e.g., worker shutdown, lingering_close) that can still abort it? - Can the upstream still observe a broken connection in some timing windows despite the directive, making the processing non-transactional?
- Is there a documented way to bound total upstream duration for abandoned requests, given that the read timeout is per-gap?