The official NGINX Open Source repository.
Go to file
Aleksei Bavshin f2fcc03d3a Resolver: make TCP write timer event cancelable.
Similar to 70e65bf8dfd7, the change is made to ensure that the ability to
cancel resolver tasks is fully controlled by the caller.  As mentioned in the
referenced commit, it is safe to make this timer cancelable because resolve
tasks can have their own timeouts that are not cancelable.

The scenario where this may become a problem is a periodic background resolve
task (not tied to a specific request or a client connection), which receives a
response with short TTL, large enough to warrant fallback to a TCP query.
With each event loop wakeup, we either have a previously set write timer
instance or schedule a new one.  The non-cancelable write timer can delay or
block graceful shutdown of a worker even if the ngx_resolver_ctx_t->cancelable
flag is set by the API user, and there are no other tasks or connections.

We use the resolver API in this way to maintain the list of upstream server
addresses specified with the 'resolve' parameter, and there could be third-party
modules implementing similar logic.
2022-06-01 20:17:23 -07:00
auto Configure: recognize arm64 machine name as a synonym for aarch64. 2022-04-29 17:38:01 +04:00
conf MIME: added image/avif type. 2021-10-25 20:49:15 +03:00
contrib Contrib: vim syntax adjusted to save cpoptions (ticket #2276). 2022-01-22 00:28:51 +03:00
docs Year 2022. 2022-02-04 13:29:31 +03:00
misc Updated OpenSSL and zlib used for win32 builds. 2022-05-24 02:51:49 +03:00
src Resolver: make TCP write timer event cancelable. 2022-06-01 20:17:23 -07:00
.hgtags release-1.21.6 tag 2022-01-25 18:03:52 +03:00