Currently querySingleType treats timeouts and authoritative negative responses (NXDOMAIN, NOERROR+empty) the same way — it silently returns empty records. This loses critical information for dnswatcher's monitoring purpose.
The resolver needs to distinguish per-server:
Timeout / no response — server is down or unreachable. Should retry (2-3 attempts with backoff).
NXDOMAIN — authoritative: domain does not exist. No retry needed.
NOERROR + empty answer — authoritative: domain exists but no records of requested type. No retry needed.
SERVFAIL / REFUSED — server error. Should retry.
Successful response with records — normal case.
This distinction is core to dnswatcher's purpose: knowing what each DNS server is doing (not responding, responding incorrectly, etc.).
The resolver should:
Retry on timeout/SERVFAIL with exponential backoff (2-3 attempts)
Return structured results that indicate the response type per server
Not retry on authoritative negative responses (NXDOMAIN, NOERROR+empty)
Surface per-server failure modes in notifications
Currently `querySingleType` treats timeouts and authoritative negative responses (NXDOMAIN, NOERROR+empty) the same way — it silently returns empty records. This loses critical information for dnswatcher's monitoring purpose.
The resolver needs to distinguish per-server:
1. **Timeout / no response** — server is down or unreachable. Should retry (2-3 attempts with backoff).
2. **NXDOMAIN** — authoritative: domain does not exist. No retry needed.
3. **NOERROR + empty answer** — authoritative: domain exists but no records of requested type. No retry needed.
4. **SERVFAIL / REFUSED** — server error. Should retry.
5. **Successful response with records** — normal case.
This distinction is core to dnswatcher's purpose: knowing what each DNS server is doing (not responding, responding incorrectly, etc.).
The resolver should:
- Retry on timeout/SERVFAIL with exponential backoff (2-3 attempts)
- Return structured results that indicate the response type per server
- Not retry on authoritative negative responses (NXDOMAIN, NOERROR+empty)
- Surface per-server failure modes in notifications
clawbot
self-assigned this 2026-02-28 12:20:11 +01:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Currently
querySingleTypetreats timeouts and authoritative negative responses (NXDOMAIN, NOERROR+empty) the same way — it silently returns empty records. This loses critical information for dnswatcher's monitoring purpose.The resolver needs to distinguish per-server:
This distinction is core to dnswatcher's purpose: knowing what each DNS server is doing (not responding, responding incorrectly, etc.).
The resolver should:
Fix submitted in PR #36.
The resolver now:
StatusTimeoutfor persistent timeouts (distinct fromStatusError)StatusNXDomain/StatusNoDatafor authoritative negatives without retryNameserverResponse.Errorwith structured failure descriptionsmake checkpasses clean (0 linter issues, all tests pass).