4 implementations of IBufferDistributedCache
Microsoft.Extensions.Caching.Hybrid.Tests (2)
BufferReleaseTests.cs (1)
78private class TestCache : MemoryDistributedCache, IBufferDistributedCache
L2Tests.cs (1)
157private class BufferLoggingCache : LoggingCache, IBufferDistributedCache
Microsoft.Extensions.Caching.SqlServer (1)
SqlServerCache.cs (1)
19public class SqlServerCache : IDistributedCache, IBufferDistributedCache
Microsoft.Extensions.Caching.StackExchangeRedis (1)
RedisCache.cs (1)
24public partial class RedisCache : IBufferDistributedCache, IDisposable
29 references to IBufferDistributedCache
Microsoft.Extensions.Caching.Hybrid (5)
Internal\DefaultHybridCache.cs (1)
80IBufferDistributedCache => CacheFeatures.BackendCache | CacheFeatures.BackendBuffers,
Internal\DefaultHybridCache.L2.cs (4)
38var cache = Unsafe.As<IBufferDistributedCache>(_backendCache!); // type-checked already 85var cache = Unsafe.As<IBufferDistributedCache>(_backendCache!); // type-checked already
Microsoft.Extensions.Caching.Hybrid.Tests (12)
BufferReleaseTests.cs (4)
85void IBufferDistributedCache.Set(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options) 88ValueTask IBufferDistributedCache.SetAsync(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options, CancellationToken token) 91bool IBufferDistributedCache.TryGet(string key, IBufferWriter<byte> destination) 94async ValueTask<bool> IBufferDistributedCache.TryGetAsync(string key, IBufferWriter<byte> destination, CancellationToken token)
DistributedCacheTests.cs (4)
172var cache = (await InitAsync()).BuildServiceProvider().GetService<IDistributedCache>() as IBufferDistributedCache; 234var cache = (await InitAsync()).BuildServiceProvider().GetService<IDistributedCache>() as IBufferDistributedCache;
L2Tests.cs (4)
164void IBufferDistributedCache.Set(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options) 171ValueTask IBufferDistributedCache.SetAsync(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options, CancellationToken token) 178bool IBufferDistributedCache.TryGet(string key, IBufferWriter<byte> destination) 192async ValueTask<bool> IBufferDistributedCache.TryGetAsync(string key, IBufferWriter<byte> destination, CancellationToken token)
Microsoft.Extensions.Caching.MicroBenchmarks (4)
DistributedCacheBenchmarks.cs (4)
18private readonly IBufferDistributedCache sqlServer, redis; 47private IBufferDistributedCache _backend = null!; 58sqlServer = (IBufferDistributedCache)services.BuildServiceProvider().GetRequiredService<IDistributedCache>(); 66redis = (IBufferDistributedCache)services.BuildServiceProvider().GetRequiredService<IDistributedCache>();
Microsoft.Extensions.Caching.SqlServer (4)
SqlServerCache.cs (4)
86bool IBufferDistributedCache.TryGet(string key, IBufferWriter<byte> destination) 112async ValueTask<bool> IBufferDistributedCache.TryGetAsync(string key, IBufferWriter<byte> destination, CancellationToken token) 182void IBufferDistributedCache.Set(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options) 215async ValueTask IBufferDistributedCache.SetAsync(
Microsoft.Extensions.Caching.StackExchangeRedis (4)
RedisCache.cs (4)
156void IBufferDistributedCache.Set(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options) 203ValueTask IBufferDistributedCache.SetAsync(string key, ReadOnlySequence<byte> value, DistributedCacheEntryOptions options, CancellationToken token) 694bool IBufferDistributedCache.TryGet(string key, IBufferWriter<byte> destination) 740async ValueTask<bool> IBufferDistributedCache.TryGetAsync(string key, IBufferWriter<byte> destination, CancellationToken token)