bluele / gcache

An in-memory cache library for golang. It supports multiple eviction policies: LRU, LFU, ARC
MIT License
2.6k stars 271 forks source link

Batch operations are very common. Do you consider supporting batch read and batch load interfaces? #66

Open 826409960 opened 4 years ago

826409960 commented 4 years ago

`type Cache interface { Set(key, value interface{}) error SetWithExpire(key, value interface{}, expiration time.Duration) error Get(key interface{}) (interface{}, error) GetIFPresent(key interface{}) (interface{}, error) GetALL(checkExpired bool) map[interface{}]interface{} get(key interface{}, onLoad bool) (interface{}, error) Remove(key interface{}) bool Purge() Keys(checkExpired bool) []interface{} Len(checkExpired bool) int Has(key interface{}) bool

statsAccessor

}` like BatchSet and BatchGet