bug 394- Change DNS agent to allow sending asyncronus dns queries.
Review Request #94 — Created Nov. 21, 2023 and submitted — Latest diff uploaded
| Information | |
|---|---|
| tanya | |
| APV10 | |
| rel_apv_10.7, rel_apv_10_4_2_104 | |
| 394 | |
| Reviewers | |
| kdutta, timlai, wli | |
Current Agent DNS blocks on each DNS query it issues. It spans off an nslookup request and blocks until reply is received and processed. This causes a problem when DNS server is not replying promptly because no other queries can be send out and no other requests from WebAgent can be processed
New code allows to send out DNS request in non-blocking manner and then poll for DNS responses. Once DNS response becomes available it can be sent back to WebAgent.
This code is uses getaddrinfo_a() function. To send the dns request. It’s a standard function and more details can be found at https://man7.org/linux/man-pages/man3/getaddrinfo_a.3.html. The getaddrinfo_a() will be called from domain_resolve_asynch()More info in the confluence -https://arraynetworks.atlassian.net/wiki/download/attachments/163842/DNS_agent_async_lookup_design.docx?version=1&modificationDate=1700512503628&cacheVersion=1&api=v2
unit tested when initially was develoed in 10.4.2.104. DNS code is the same as in the branch where it was originaly tested, so I did not retest after porting to this branch
