Innovabit.DotNet.Interceptors.Caching.Hybrid 2.0.119

dotnet add package Innovabit.DotNet.Interceptors.Caching.Hybrid --version 2.0.119
                    
NuGet\Install-Package Innovabit.DotNet.Interceptors.Caching.Hybrid -Version 2.0.119
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Innovabit.DotNet.Interceptors.Caching.Hybrid" Version="2.0.119" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Innovabit.DotNet.Interceptors.Caching.Hybrid" Version="2.0.119" />
                    
Directory.Packages.props
<PackageReference Include="Innovabit.DotNet.Interceptors.Caching.Hybrid" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Innovabit.DotNet.Interceptors.Caching.Hybrid --version 2.0.119
                    
#r "nuget: Innovabit.DotNet.Interceptors.Caching.Hybrid, 2.0.119"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Innovabit.DotNet.Interceptors.Caching.Hybrid@2.0.119
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Innovabit.DotNet.Interceptors.Caching.Hybrid&version=2.0.119
                    
Install as a Cake Addin
#tool nuget:?package=Innovabit.DotNet.Interceptors.Caching.Hybrid&version=2.0.119
                    
Install as a Cake Tool

Innovabit.DotNet.Interceptors.Caching.Hybrid

HybridCache store provider for Innovabit.DotNet.Interceptors.Caching.Abstractions: an in-process L1 in front of whatever distributed L2 you configured, with stampede protection built in.

One store, two tiers. A hit usually never leaves the process, a miss falls through to the distributed cache, and concurrent misses for the same key collapse into a single read — close to [Cache] + [SingleFlight] + the Redis store in one dependency.

Usage

services.AddStackExchangeRedisCache(o => o.Configuration = "localhost:6379");   // the L2, optional
services.AddHybridCache();                                                      // Microsoft's own

services
    .AddInterceptors()
    .AddHybridCacheStore();

services.AddScopedWithInterception<IPriceService, PriceService>();

Without an IDistributedCache registered, HybridCache runs L1-only — still useful for the stampede protection alone.

The extension is AddHybridCacheStore, not AddHybridCache, so it cannot be mistaken for Microsoft's own registration. You need both.

What to know

A sliding expiration is honoured as an absolute one. HybridCache has no sliding expiration, so [Cache(SlidingExpirationSeconds = 60)] gives an entry that lives at most a minute rather than a minute past its last read. The entry expires sooner than asked for, never later, which is the safe direction to be wrong in for a cache — but it is a different policy, and a method that genuinely relies on sliding behaviour wants the in-memory or Redis store.

Values are wrapped in a HybridCacheEnvelope<T>. HybridCache exposes no plain read — only GetOrCreateAsync, which cannot say whether it found an entry or created one. Reading through a factory that yields nothing answers that, but only if "nothing" cannot also be a legitimate cached value. The envelope is what keeps a stored null distinguishable from a miss. It is public, so registering your own IHybridCacheSerializer<HybridCacheEnvelope<T>> is a supported way to change how entries are written.

Reads never write. The read path disables both cache tiers' writes, so the "not found" its factory yields is never stored.

License

MIT

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.0.119 52 11/14/2026
2.0.118 104 11/7/2026
2.0.117 109 10/31/2026
2.0.116 105 10/26/2026
2.0.115 114 10/17/2026
2.0.114 108 10/10/2026
2.0.113 112 10/3/2026
2.0.112 105 9/28/2026
2.0.111 103 9/28/2026
2.0.110 105 9/27/2026
2.0.109 99 9/26/2026
2.0.108 98 9/26/2026
2.0.107 112 9/26/2026
2.0.106 112 9/25/2026
2.0.105 112 9/25/2026
1.0.0.104 100 9/25/2026