d2aa144dcc
syncs: bump known good version to include Go 1.17
...
Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com >
2021-08-17 11:13:03 -07:00
a5da4ed981
all: gofmt with Go 1.17
...
This adds "//go:build" lines and tidies up existing "// +build" lines.
Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com >
2021-08-05 15:54:00 -07:00
e4fecfe31d
wgengine/{monitor,router}: restore Linux ip rules when systemd deletes them
...
Thanks.
Fixes #1591
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com >
2021-07-20 15:52:22 -07:00
676e32ad72
syncs: add AtomicUint32
...
Signed-off-by: David Crawshaw <crawshaw@tailscale.com >
2021-06-23 08:51:37 -07:00
297b3d6fa4
staticcheck.conf: turn off noisy lint errors
...
Signed-off-by: David Crawshaw <crawshaw@tailscale.com >
2021-06-18 15:48:20 -07:00
d3ba860ffd
syncs: stop running TestWatchMultipleValues on CI
...
It's flaky, and not just on Windows.
Signed-off-by: Josh Bleecher Snyder <josharian@gmail.com >
2021-05-04 10:21:21 -07:00
0807e3e2f7
syncs: disable TestWatchMultipleValues on Windows CI builds
...
The Windows CI machine experiences significant random execution delays.
For example, in this code from watchdog.go:
done := make(chan bool)
go func() {
start := time.Now()
mu.Lock()
There was a 500ms delay from initializing done to locking mu.
This test checks that we receive a sufficient number of events quickly enough.
In the face of random 500ms delays, unsurprisingly, the test fails.
There's not much principled we can do about it.
We could build a system of retries or attempt to detect these random delays,
but that game isn't worth the candle.
Skip the test.
Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com >
2021-03-27 13:25:33 -07:00
77ec80538a
syncs: add Semaphore
...
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com >
2021-03-23 12:39:28 -07:00
c431382720
Fix receiver in order to be consistent: syncs.WaitGroupChan
...
Signed-off-by: Dmytro Tananayskiy <dmitriyminer@gmail.com >
2020-11-24 17:20:34 -08:00
9ab2b32569
syncs: add Watch, for monitoring mutex contention
...
Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com >
2020-09-11 11:36:07 -07:00
bf24d54143
syncs: add AssertLocked
...
This allows us to check lock invariants.
It was proposed upstream and rejected in:
https://github.com/golang/go/issues/1366
Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com >
2020-09-09 12:27:52 -07:00
d3134ad0c8
syncs: add AtomicBool
2020-05-29 12:41:30 -07:00
b4d02a251a
syncs: add new package for extra sync types
2020-03-12 11:13:33 -07:00