fix(hetznercloud): poll zone action endpoint instead of server action - #1177
Open
legend813 wants to merge 1 commit into
Open
fix(hetznercloud): poll zone action endpoint instead of server action#1177legend813 wants to merge 1 commit into
legend813 wants to merge 1 commit into
Conversation
Record writes return an action that belongs to the zone, so it must be
polled at /v1/zones/actions/{id}. Polling /v1/servers/actions/{id}
returns 404 not_found, which is turned into an update failure even
though the record write itself succeeded.
As a result updates.json is never updated, the Web UI keeps showing a
stale current IP, and the healthcheck keeps the container unhealthy.
Adds a regression test asserting the polled path.
Fixes qdm12#1136
Owner
|
Isn't this the same as now-merged #1166 ? |
Contributor
|
Yes, same change as #1166. The diff is identical, and |
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.
What
waitActionfor thehetznercloudprovider polls the server action endpoint for what is a zone action:Record writes (
add_rrset_records,set_rrset_records, …) return an action that lives under/v1/zones/actions/{id}. Looking it up under/v1/servers/actions/{id}returns404 not_found, whichhandleErrorResponseturns into an update failure — even though the record write itself succeeded.Why it matters
The DNS record is written correctly, but the update is recorded as failed. Consequences reported in #1136:
updates.jsonis never updated, so the Web UI shows a stale "Current IP" indefinitelyunhealthyReproduction
Against a live Hetzner Cloud DNS zone, using the same action ID returned by a record write:
Same ID, both endpoints — only the zone one resolves. On accounts with no cloud servers,
/v1/servers/actionsis empty, so every lookup necessarily 404s.Change
One-line fix plus a regression test that asserts the polled path and covers the
erroraction status.Verified on
v2.10.0(commit 6499618) against a real zone: with the fix, record updates are recorded as successful.Fixes #1136