Content-Length: 338865 | pFad | https://github.com/nghttp2/nghttp2/pull/2344

27 nghttpx: Tweak DNS timeout and retry by tatsuhiro-t · Pull Request #2344 · nghttp2/nghttp2 · GitHub
Skip to content

nghttpx: Tweak DNS timeout and retry#2344

Merged
tatsuhiro-t merged 1 commit intomasterfrom
nghttpx-dns
May 2, 2025
Merged

nghttpx: Tweak DNS timeout and retry#2344
tatsuhiro-t merged 1 commit intomasterfrom
nghttpx-dns

Conversation

@tatsuhiro-t
Copy link
Member

Decrease DNS timeout to 250ms, which is the minimum duration allowed in c-ares. The number of retries is 3, which is the default value of c-ares.

Decrease DNS timeout to 250ms, which is the minimum duration allowed
in c-ares.  The number of retries is 3, which is the default value of
c-ares.
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adjusts the DNS lookup timeout and retry parameters in nghttpx to align with c-ares constraints.

  • Decreases the DNS lookup timeout from 5 seconds to 250ms.
  • Updates the retry count from 2 to 3 to match c-ares’ default.

@@ -2200,9 +2200,9 @@ void fill_default_config(Config *config) {
{
auto &timeoutconf = dnsconf.timeout;
timeoutconf.cache = 10_s;
Copy link

Copilot AI May 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding an inline comment here to note that 250_ms is chosen because it is the minimum timeout allowed by c-ares.

Suggested change
timeoutconf.cache = 10_s;
timeoutconf.cache = 10_s;
// 250_ms is chosen because it is the minimum timeout allowed by c-ares.

Copilot uses AI. Check for mistakes.
timeoutconf.cache = 10_s;
timeoutconf.lookup = 5_s;
timeoutconf.lookup = 250_ms;
}
Copy link

Copilot AI May 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding an inline comment explaining that the retry count is updated to 3 to match the default value of c-ares.

Suggested change
}
}
// Set the retry count to 3 to match the default value of c-ares.

Copilot uses AI. Check for mistakes.
@tatsuhiro-t tatsuhiro-t merged commit fcd710e into master May 2, 2025
87 checks passed
@tatsuhiro-t tatsuhiro-t deleted the nghttpx-dns branch May 2, 2025 14:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants









ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/nghttp2/nghttp2/pull/2344

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy