feat(hetzner): make Hetzner Cloud API HTTP timeout configurable - #212
Open
roshanavand wants to merge 2 commits into
Open
feat(hetzner): make Hetzner Cloud API HTTP timeout configurable#212roshanavand wants to merge 2 commits into
roshanavand wants to merge 2 commits into
Conversation
hetzner#91 set the per-request HTTP client timeout to a hardcoded 15s so that a blocked/unreachable API (hetzner#73) fails fast instead of hanging, relying on the SDK's own retry loop (5 retries, exponential backoff) to keep overall latency bounded. That same fixed value can also be too short for a slow-but-reachable Hetzner Cloud Zones API response, causing DNS-01 record creation or cleanup to intermittently fail with the same timeout error after exhausting all retries, even though the API is healthy. Add an optional httpTimeout field to the Issuer solver config (a Go duration string, e.g. "45s") so this can be tuned per-environment without a custom image. The 15s default is unchanged, since raising it would also raise the worst-case duration of the retry loop hetzner#91 relies on to stay under whatever imposes the outer deadline in the truly-unreachable case.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#91 set the per-request HTTP client timeout to a hardcoded 15s so that a blocked/unreachable API (#73) fails fast instead of hanging, relying on the SDK's own retry loop (5 retries, exponential backoff) to keep overall latency bounded.
That same fixed value can also be too short for a slow-but-reachable Hetzner Cloud Zones API response, causing DNS-01 record creation or cleanup to intermittently fail with the same timeout error after exhausting all retries, even though the API is healthy.
Add an optional httpTimeout field to the Issuer solver config (a Go duration string, e.g. "45s") so this can be tuned per-environment without a custom image. The 15s default is unchanged, since raising it would also raise the worst-case duration of the retry loop #91 relies on to stay under whatever imposes the outer deadline in the truly-unreachable case.