engine/cache/mem/mem.go

15 lines
277 B
Go

package mem
import (
"git.apinb.com/bsm-sdk/engine/vars"
"github.com/FishGoddess/cachego"
)
func New() cachego.Cache {
return cachego.NewCache(
cachego.WithGC(vars.MemGcDuration),
cachego.WithShardings(vars.MemShardings),
cachego.WithLFU(vars.MemLRUMaxNumber),
)
}