From d8174deb2d6ed689ff4db7e264e512101e062d4b Mon Sep 17 00:00:00 2001 From: Wez Furlong Date: Sat, 24 Jun 2023 10:13:47 -0700 Subject: [PATCH] fix NXDOMAIN issue showing up as no non-zero-weighted sources The suspension logic changed things so that we'd trip over a DNS resolution earlier than normal, inside the round robin routine. That isn't capable of reporting the domain resolution issue and it would bubble up as NoSources and we'd miscategorize the failure. This commit addresses that by allowing the round robin to pick a source and then we can subsequently bubble up and handle the domain resolution issue as normal. --- crates/kumod/src/egress_source.rs | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/crates/kumod/src/egress_source.rs b/crates/kumod/src/egress_source.rs index 0fb24aa1..11b52672 100644 --- a/crates/kumod/src/egress_source.rs +++ b/crates/kumod/src/egress_source.rs @@ -378,6 +378,17 @@ impl EgressPoolRoundRobin { entries.push(entry.clone()); } } + } else { + // Likely a DNS resolution issue that prevented us from computing + // the site name to use for the ready queue. + // We're not in an appropriate context to handle that issue here, + // but the good news is that without a valid site name, there can't + // possibly be any suspensions for a ready queue that we can't name + // so we can continue to populate the entries and pick one. + // The DNS issue will bubble up almost immediately after we return + // a source name as our caller will call + // ReadyQueueManager::resolve_by_queue_name which will surface it. + entries.push(entry.clone()); } }