micro-registry-cache/options.go
2020-09-20 17:12:31 +03:00

13 lines
148 B
Go

package cache
import (
"time"
)
// WithTTL sets the cache TTL
func WithTTL(t time.Duration) Option {
return func(o *Options) {
o.TTL = t
}
}