You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tailscale/wgengine/magicsock
Andrew Dunham 80b138f0df wgengine/magicsock: keep advertising endpoints after we stop discovering them
Previously, when updating endpoints we would immediately stop
advertising any endpoint that wasn't discovered during
determineEndpoints. This could result in, for example, a case where we
performed an incremental netcheck, didn't get any of our three STUN
packets back, and then dropped our STUN endpoint from the set of
advertised endpoints... which would result in clients falling back to a
DERP connection until the next call to determineEndpoints.

Instead, let's cache endpoints that we've discovered and continue
reporting them to clients until a timeout expires. In the above case
where we temporarily don't have a discovered STUN endpoint, we would
continue reporting the old value, then re-discover the STUN endpoint
again and continue reporting it as normal, so clients never see a
withdrawal.

Updates tailscale/coral#108

Signed-off-by: Andrew Dunham <andrew@du.nham.ca>
Change-Id: I42de72e7418ab328a6c732bdefc74549708cf8b9
1 year ago
..
debughttp.go all: update copyright and license headers 1 year ago
debugknobs.go derp,magicsock: add debug envknobs for HTTP and derp server name (#7744) 1 year ago
debugknobs_stubs.go derp,magicsock: add debug envknobs for HTTP and derp server name (#7744) 1 year ago
discopingpurpose_string.go all: update copyright and license headers 1 year ago
magicsock.go wgengine/magicsock: keep advertising endpoints after we stop discovering them 1 year ago
magicsock_default.go net/neterror, wgengine/magicsock: use UDP GSO and GRO on Linux (#7791) 1 year ago
magicsock_linux.go net/neterror, wgengine/magicsock: use UDP GSO and GRO on Linux (#7791) 1 year ago
magicsock_test.go wgengine/magicsock: keep advertising endpoints after we stop discovering them 1 year ago
magicsock_unix_test.go all: update copyright and license headers 1 year ago
pathfinder.go all: update copyright and license headers 1 year ago