[PR #1181] [MERGED] Only fall back on TCP if cons are available #2047

Closed
opened 2026-03-16 05:01:00 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hickory-dns/hickory-dns/pull/1181
Author: @lukaspustina
Created: 8/6/2020
Status: Merged
Merged: 8/6/2020
Merged by: @bluejekyll

Base: mainHead: main


📝 Commits (2)

  • 3aaccab Only fall back on TCP if cons are available
  • 2abfc23 Rust format

📊 Changes

1 file changed (+8 additions, -2 deletions)

View changed files

📝 crates/resolver/src/name_server/name_server_pool.rs (+8 -2)

📄 Description

NameServerPool falls back on TCP if UDP fails, e.g., due to a timeout. It does
this even when no TCP connections are available. This obscures the underlying UDP
error by ProtoError::from("No connections available").

This commit changes this behavior by checking if TCP connections are available
first and if not, passing the original UDP error along.


🔄 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/1181 **Author:** [@lukaspustina](https://github.com/lukaspustina) **Created:** 8/6/2020 **Status:** ✅ Merged **Merged:** 8/6/2020 **Merged by:** [@bluejekyll](https://github.com/bluejekyll) **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (2) - [`3aaccab`](https://github.com/hickory-dns/hickory-dns/commit/3aaccabf5be6bfb749e76144b62699a5a31ac6ef) Only fall back on TCP if cons are available - [`2abfc23`](https://github.com/hickory-dns/hickory-dns/commit/2abfc23ba58d78218bea035b7e980bb709c50139) Rust format ### 📊 Changes **1 file changed** (+8 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `crates/resolver/src/name_server/name_server_pool.rs` (+8 -2) </details> ### 📄 Description `NameServerPool` falls back on TCP if UDP fails, e.g., due to a timeout. It does this even when no TCP connections are available. This obscures the underlying UDP error by `ProtoError::from("No connections available")`. This commit changes this behavior by checking if TCP connections are available first and if not, passing the original UDP error along. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-16 05:01:00 +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#2047
No description provided.