util/ringbuffer: rename to ringlog
I need a ringbuffer in the more traditional sense, one that has a notion of item removal as well as tail loss on overrun. This implementation is really a clearable log window, and is used as such where it is used. Updates #cleanup Updates tailscale/corp#31762 Signed-off-by: James Tucker <james@tailscale.com>
This commit is contained in:
committed by
James Tucker
parent
4b9a1a0087
commit
d42f0b6a21
@@ -33,7 +33,7 @@ import (
|
||||
"tailscale.com/types/key"
|
||||
"tailscale.com/types/logger"
|
||||
"tailscale.com/util/mak"
|
||||
"tailscale.com/util/ringbuffer"
|
||||
"tailscale.com/util/ringlog"
|
||||
"tailscale.com/util/slicesx"
|
||||
)
|
||||
|
||||
@@ -60,7 +60,7 @@ type endpoint struct {
|
||||
lastRecvWG mono.Time // last time there were incoming packets from this peer destined for wireguard-go (e.g. not disco)
|
||||
lastRecvUDPAny mono.Time // last time there were incoming UDP packets from this peer of any kind
|
||||
numStopAndResetAtomic int64
|
||||
debugUpdates *ringbuffer.RingBuffer[EndpointChange]
|
||||
debugUpdates *ringlog.RingLog[EndpointChange]
|
||||
|
||||
// These fields are initialized once and never modified.
|
||||
c *Conn
|
||||
|
||||
Reference in New Issue
Block a user