[PR #485] [MERGED] resolver: Propagate TTLs for NXDOMAIN responses #1471

Closed
opened 2026-03-16 02:08:23 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hickory-dns/hickory-dns/pull/485
Author: @hawkw
Created: 5/23/2018
Status: Merged
Merged: 5/24/2018
Merged by: @bluejekyll

Base: masterHead: eliza/nxerror-propagates-ttls


📝 Commits (1)

  • 9bbdb81 resolver: Propagate TTLs for NXDOMAIN responses

📊 Changes

4 files changed (+28 additions, -13 deletions)

View changed files

📝 resolver/src/dns_lru.rs (+3 -3)
📝 resolver/src/error.rs (+13 -4)
📝 resolver/src/lookup.rs (+4 -1)
📝 resolver/src/lookup_state.rs (+8 -5)

📄 Description

Since 21c666ddb3, we've exposed the deadlines for successful DNS lookups to users of the Resolver API. This PR adds a valid_until field to the ResolveErrorKind::NoRecordsFound variant as well, so the TTLs for NXDOMAIN responses are also accessible to the user. This is necessary in situations where the user has implemented their own caching separate from Trust-DNS' cache.

Signed-off-by: Eliza Weisman eliza@buoyant.io


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/hickory-dns/hickory-dns/pull/485 **Author:** [@hawkw](https://github.com/hawkw) **Created:** 5/23/2018 **Status:** ✅ Merged **Merged:** 5/24/2018 **Merged by:** [@bluejekyll](https://github.com/bluejekyll) **Base:** `master` ← **Head:** `eliza/nxerror-propagates-ttls` --- ### 📝 Commits (1) - [`9bbdb81`](https://github.com/hickory-dns/hickory-dns/commit/9bbdb812999ae168b9f4d241b9b10175155a544d) resolver: Propagate TTLs for NXDOMAIN responses ### 📊 Changes **4 files changed** (+28 additions, -13 deletions) <details> <summary>View changed files</summary> 📝 `resolver/src/dns_lru.rs` (+3 -3) 📝 `resolver/src/error.rs` (+13 -4) 📝 `resolver/src/lookup.rs` (+4 -1) 📝 `resolver/src/lookup_state.rs` (+8 -5) </details> ### 📄 Description Since 21c666ddb3975508b0bca90224fba6caccf15107, we've exposed the deadlines for successful DNS lookups to users of the `Resolver` API. This PR adds a `valid_until` field to the `ResolveErrorKind::NoRecordsFound` variant as well, so the TTLs for NXDOMAIN responses are also accessible to the user. This is necessary in situations where the user has implemented their own caching separate from `Trust-DNS`' cache. Signed-off-by: Eliza Weisman <eliza@buoyant.io> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-16 02:08:23 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hickory-dns#1471
No description provided.