SkillAgentSearch skills...

Lru

Go package lru implements Least Recently Used cache algorithm.

Install / Use

/learn @dchest/Lru
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

Go package lru implements 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 time.

INSTALLATION

$ go get github.com/dchest/lru/v2

DOCUMENTATION

See https://pkg.go.dev/github.com/dchest/lru/v2

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 Stars19
CategoryDevelopment
Updated15h ago
Forks3

Languages

Go

Security Score

90/100

Audited on Apr 1, 2026

No findings