Resolver: introduced state field in ngx_resolver_srv_name_t.

It keeps the actual state value of a DNS SRV subrequest
and can be used to report a more detailed log for
failed SRV records.
This commit is contained in:
Dmitry Volyntsev 2016-09-29 19:40:47 +03:00
parent c7a6a18163
commit 833d03a0a2
2 changed files with 2 additions and 0 deletions

View File

@ -3006,6 +3006,7 @@ ngx_resolver_srv_names_handler(ngx_resolver_ctx_t *cctx)
ctx->count--;
srv->ctx = NULL;
srv->state = cctx->state;
if (cctx->naddrs) {

View File

@ -82,6 +82,7 @@ typedef struct {
u_short port;
ngx_resolver_ctx_t *ctx;
ngx_int_t state;
ngx_uint_t naddrs;
ngx_addr_t *addrs;