golang-lru is a thread-safe LRU cache implementation for Go.
The project solves the problem of efficiently caching a bounded set of items in memory while automatically evicting the least recently used entries when capacity is reached. It provides a fixed-size cache that maintains thread safety, allowing concurrent access from multiple goroutines without external synchronization. The implementation is based on the cache design from Groupcache.
The tool suits applications that need fast in-memory caching with predictable memory bounds. It is particularly useful in scenarios where you want to avoid unbounded memory growth from caching while keeping frequently accessed items readily available. The project offers both a standard LRU cache and an expirable variant, giving developers flexibility in how items are retained and evicted.
The project maintains a steady stream of updates and refinements. Pull requests are reviewed and merged regularly, indicating active maintenance. Issues are addressed with reasonable responsiveness. The codebase receives periodic improvements and bug fixes without long periods of inactivity.