// the find
dotnetcore/EasyCaching
:boom: EasyCaching is an open source caching library that contains basic usages and some advanced usages of caching which can help us to handle caching more easier!
EasyCaching is a .NET caching abstraction library that wraps InMemory, Redis, Memcached, SQLite, disk, and several other backends behind a unified interface. It targets ASP.NET Core teams who want to swap cache providers without rewriting call sites, and adds hybrid (L1/L2) caching and AOP-style interceptors on top.
The hybrid cache implementation is the real reason to look at this — it wires a fast in-memory L1 tier to a distributed L2 tier and uses a message bus (Redis pub/sub, RabbitMQ, Kafka, Zookeeper) to invalidate L1 entries across nodes, which is the part most teams implement badly themselves. The interceptor support via Castle or AspectCore lets you slap `[EasyCachingAble]` on a service method and get cache-aside without touching the method body. The serialization layer is genuinely pluggable — MessagePack, MemoryPack, Protobuf, System.Text.Json, Newtonsoft — and swappable per provider. The DiagnosticListener integration means you can hook it into existing OpenTelemetry or custom tracing infrastructure without monkey-patching.
Last push was March 2025 and the pace has slowed significantly — several open issues reference .NET 8/9 behaviour that hasn't been addressed. The FasterKV backend lags the upstream FASTER library and its session pooling implementation is unlikely to hold up under high concurrency without testing. The hybrid bus invalidation is eventually consistent by design, but the docs don't quantify the window or explain what happens when the bus is partitioned — your L1 entries will serve stale data and you won't know. There's no built-in stampede protection beyond a simple mutex key with a configurable sleep loop, which degrades poorly under high concurrency compared to a proper semaphore or probabilistic early expiration approach.