Closed kyprizel closed 10 years ago
@kyprizel This could be a real issue but your patch looks wrong to me :)
I think the real issue is in ngx_memc or ngx_redis2, which both do not ignore client aborts by explicitly setting conf->upstream.ignore_client_abort = 0
. Will you submit patches to these modules and add new directives memc_ignore_client_abort
and redis2_ignore_client_abort
? Just like ngx_proxy's proxy_ignore_client_abort
directive:
http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_ignore_client_abort
Thanks!
I think in some cases (fetching the cache) we do not need to continue if the client was disconnected.
@kyprizel Easy. Just configure two separate (internal) locations for srcache_fetch
and srcache_store
, respectively. Put memc_ignore_client_abort off
in the former location and memc_ignore_client_abort on
in the latter :)
Yep :) You're right, will send request later.
Fix: If client disconnects too fast (small response body), upstream connection also closes and response will not be cached.