rtr7 / router7

router7 is a small home internet router completely written in Go. It is implemented as a gokrazy appliance.
https://router7.org
Apache License 2.0
2.69k stars 110 forks source link

internal/dns: prevent upstreams from being lost during reordering #63

Closed robryk closed 3 years ago

robryk commented 3 years ago

If upstreams were reordered between start of an upstream request and its conclusion, the move-to-front operation would likely incorrectly reorder upstreams: duplicate one and remove another. Instead, we abandon the move-to-front operation if that was about to happen.