mirror of
https://github.com/libp2p/go-libp2p-peerstore.git
synced 2025-03-23 13:00:08 +08:00
Mutex hat pattern
This commit is contained in:
parent
7e3363eeb4
commit
b550e5b2c6
@ -207,6 +207,7 @@ type ttlentry struct {
|
||||
type ttlmanager struct {
|
||||
sync.RWMutex
|
||||
entries map[ds.Key]*ttlentry
|
||||
|
||||
ctx context.Context
|
||||
cancel context.CancelFunc
|
||||
ticker *time.Ticker
|
||||
|
Loading…
Reference in New Issue
Block a user