[FIXED] Route missing after reconnect when duplicate resolution kept gossip URL - #8527
Conversation
…gossip URL Signed-off-by: Maurice van Veen <github@mauricevanveen.com>
|
Claude finished @MauriceVanVeen's task in 2m 3s —— View job PR Review: Route missing after reconnect (duplicate resolution + gossip URL)
SummaryThis is a targeted, correct fix. The bug is symmetric with the one fixed in #8454: Root CauseWhen if didSolicit && !remote.route.didSolicit { // false — remote was already solicited
remote.route.url = url // SKIPPED: gossip URL stays
}...prevented the URL upgrade. On disconnect, Fix AnalysisThe new condition mirrors // upgradeRouteToSolicited (existing, from #8454)
if !r.route.didSolicit || (rtype == Explicit && r.route.routeType != Explicit) {
r.route.url = url
}
// handleDuplicateRoute (this PR)
if !remote.route.didSolicit || (rtype == Explicit && remote.route.routeType != Explicit) {
remote.route.url = url
}The symmetry is correct. The URL is promoted to the configured one only when: (a) the remote wasn't yet soliciting, or (b) the incoming is Explicit and the remote isn't yet Explicit. In all other cases (both already Explicit, or both Implicit) the URL is left unchanged, which is safe. Concurrency: Test CoverageThe new
The test is well-structured. One minor note: the setup mutates The rename of the existing test ( VerdictLGTM. No correctness, security, or performance concerns. The fix is minimal, symmetric, and well-tested. |
Follow-up of #8454
Similarly found in Antithesis, for a
$SYSroute not re-establishing. Turned out to be the same bug as before, inhandleDuplicateRouteversusupgradeRouteToSolicited, for any duplicate pinned routes or normal duplicate routes in non-pool mode.