SkillAgentSearch skills...

Cache

Go package cache implements LRU (Least Recently Used) cache algorithm. [[ Deprecated, use https://github.com/dchest/lru ]]

Install / Use

/learn @dchest/Cache
About this skill

Quality Score

0/100

Supported Platforms

Universal

README


** This package is deprecated in favor of https://github.com/dchest/lru ***


Go package cache implements LRU (Least Recently Used) cache algorithm.

Cache capacity can be optionally limited by both size in bytes and a number of items. Items can keep track of their modification and access time.

INSTALLATION

$ go get github.com/dchest/cache

DOCUMENTATION

See http://godoc.org/github.com/dchest/cache

ACKNOWLEDGEMENTS

Some code structure ideas are inspired by YouTube's Vitess implementation of LRU cache, but no code was taken from it: https://github.com/youtube/vitess/blob/master/go/cache/lru_cache.go

Thanks to Chaker Nakhli (@nakhli) for the article: http://www.sinbadsoft.com/blog/a-lru-cache-implementation/

View on GitHub
GitHub Stars11
CategoryDevelopment
Updated7y ago
Forks1

Languages

Go

Security Score

75/100

Audited on Aug 28, 2018

No findings