-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Implement output-cache store using redis #48450
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
31 commits
Select commit
Hold shift + click to select a range
df53705
start spiking redis-cache output-cache implementation
mgravell 28bf900
basic tests
mgravell 276da17
detect server features
mgravell 1e1ff19
add DIM for read-only-sequence API
mgravell 8c4efa0
spike buffer writer store
mgravell 131f6ba
implement and test tag-based evictions
mgravell ef7dfd8
test score increase behavior
mgravell e6a55c2
naming is hard
mgravell 965ba01
nit: let's always use ARGV in forwards order (easier to grok)
mgravell 8193ec6
can't share ARGV between calls because of F+F/timing
mgravell 01e371f
return leased buffer sooner (after StringSetAsync)
mgravell ac80c07
test multi-segment writes and read-via-buffer-writer API
mgravell 8d56814
implement GC mechanism
mgravell 101bcce
use "now" as the value in the GC key
mgravell 85d439f
disable tests for CI; addressing separately
mgravell 63af7c9
Update src/Caching/StackExchangeRedis/src/RedisOutputCacheStore.cs
mgravell e3baab3
use TaskCreationOptions.LongRunning
mgravell f909280
fix CI fail
mgravell f59948d
Merge branch 'marc/ocredis' of https://github.com/dotnet/aspnetcore i…
mgravell 2b4740d
prefer TryAddSingleton
mgravell 3cd3967
split fields onto separate lines
mgravell ee5125f
update API as per discussion
mgravell fb7b1e6
fix failing test (from nit fixes)
mgravell 8dd9a21
use CTS to interrupt server GC
mgravell f79e65d
switch from magic number in `long` result to `long?`
mgravell a74ec43
delete copy/pasta
mgravell e5fa501
fix DEBUG/RELEASE snafu
mgravell 757441c
include output cache middleware in caching proj
mgravell 2e1d87d
API feedback; IBufferWriter<byte> -> PipeWriter
mgravell 56baf49
fix magic numbers test snafu
mgravell b1feb8f
clarify future PipeWriter usage
mgravell File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
26 changes: 26 additions & 0 deletions
26
src/Caching/StackExchangeRedis/src/PublicAPI/net8.0/PublicAPI.Shipped.txt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#nullable enable | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Dispose() -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Get(string! key) -> byte[]? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.GetAsync(string! key, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)) -> System.Threading.Tasks.Task<byte[]?>! | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.RedisCache(Microsoft.Extensions.Options.IOptions<Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions!>! optionsAccessor) -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Refresh(string! key) -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.RefreshAsync(string! key, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)) -> System.Threading.Tasks.Task! | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Remove(string! key) -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.RemoveAsync(string! key, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)) -> System.Threading.Tasks.Task! | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Set(string! key, byte[]! value, Microsoft.Extensions.Caching.Distributed.DistributedCacheEntryOptions! options) -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.SetAsync(string! key, byte[]! value, Microsoft.Extensions.Caching.Distributed.DistributedCacheEntryOptions! options, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)) -> System.Threading.Tasks.Task! | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.Configuration.get -> string? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.Configuration.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ConfigurationOptions.get -> StackExchange.Redis.ConfigurationOptions? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ConfigurationOptions.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ConnectionMultiplexerFactory.get -> System.Func<System.Threading.Tasks.Task<StackExchange.Redis.IConnectionMultiplexer!>!>? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ConnectionMultiplexerFactory.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.InstanceName.get -> string? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.InstanceName.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ProfilingSession.get -> System.Func<StackExchange.Redis.Profiling.ProfilingSession!>? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ProfilingSession.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.RedisCacheOptions() -> void | ||
Microsoft.Extensions.DependencyInjection.StackExchangeRedisCacheServiceCollectionExtensions | ||
static Microsoft.Extensions.DependencyInjection.StackExchangeRedisCacheServiceCollectionExtensions.AddStackExchangeRedisCache(this Microsoft.Extensions.DependencyInjection.IServiceCollection! services, System.Action<Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions!>! setupAction) -> Microsoft.Extensions.DependencyInjection.IServiceCollection! |
2 changes: 2 additions & 0 deletions
2
src/Caching/StackExchangeRedis/src/PublicAPI/net8.0/PublicAPI.Unshipped.txt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#nullable enable | ||
static Microsoft.Extensions.DependencyInjection.StackExchangeRedisCacheServiceCollectionExtensions.AddStackExchangeRedisOutputCache(this Microsoft.Extensions.DependencyInjection.IServiceCollection! services, System.Action<Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions!>! setupAction) -> Microsoft.Extensions.DependencyInjection.IServiceCollection! |
26 changes: 26 additions & 0 deletions
26
src/Caching/StackExchangeRedis/src/PublicAPI/netstandard2.0/PublicAPI.Shipped.txt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#nullable enable | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Dispose() -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Get(string! key) -> byte[]? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.GetAsync(string! key, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)) -> System.Threading.Tasks.Task<byte[]?>! | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.RedisCache(Microsoft.Extensions.Options.IOptions<Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions!>! optionsAccessor) -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Refresh(string! key) -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.RefreshAsync(string! key, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)) -> System.Threading.Tasks.Task! | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Remove(string! key) -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.RemoveAsync(string! key, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)) -> System.Threading.Tasks.Task! | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.Set(string! key, byte[]! value, Microsoft.Extensions.Caching.Distributed.DistributedCacheEntryOptions! options) -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCache.SetAsync(string! key, byte[]! value, Microsoft.Extensions.Caching.Distributed.DistributedCacheEntryOptions! options, System.Threading.CancellationToken token = default(System.Threading.CancellationToken)) -> System.Threading.Tasks.Task! | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.Configuration.get -> string? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.Configuration.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ConfigurationOptions.get -> StackExchange.Redis.ConfigurationOptions? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ConfigurationOptions.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ConnectionMultiplexerFactory.get -> System.Func<System.Threading.Tasks.Task<StackExchange.Redis.IConnectionMultiplexer!>!>? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ConnectionMultiplexerFactory.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.InstanceName.get -> string? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.InstanceName.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ProfilingSession.get -> System.Func<StackExchange.Redis.Profiling.ProfilingSession!>? | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.ProfilingSession.set -> void | ||
Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions.RedisCacheOptions() -> void | ||
Microsoft.Extensions.DependencyInjection.StackExchangeRedisCacheServiceCollectionExtensions | ||
static Microsoft.Extensions.DependencyInjection.StackExchangeRedisCacheServiceCollectionExtensions.AddStackExchangeRedisCache(this Microsoft.Extensions.DependencyInjection.IServiceCollection! services, System.Action<Microsoft.Extensions.Caching.StackExchangeRedis.RedisCacheOptions!>! setupAction) -> Microsoft.Extensions.DependencyInjection.IServiceCollection! |
1 change: 1 addition & 0 deletions
1
src/Caching/StackExchangeRedis/src/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
#nullable enable |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.