Mutex hat pattern

This commit is contained in:
Cole Brown 2018-06-15 17:35:47 -04:00
parent 7e3363eeb4
commit b550e5b2c6

View File

@ -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