-
Notifications
You must be signed in to change notification settings - Fork 687
Add Aspire.Microsoft.Azure.StackExchangeRedis component for Azure Cache for Redis with Azure AD authentication #11141
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
base: main
Are you sure you want to change the base?
Conversation
…functionality Co-authored-by: eerhardt <[email protected]>
…tation with tests Co-authored-by: eerhardt <[email protected]>
...s/Aspire.Microsoft.Azure.StackExchangeRedis/Aspire.Microsoft.Azure.StackExchangeRedis.csproj
Outdated
Show resolved
Hide resolved
...s/Aspire.Microsoft.Azure.StackExchangeRedis/Aspire.Microsoft.Azure.StackExchangeRedis.csproj
Outdated
Show resolved
Hide resolved
src/Components/Aspire.Microsoft.Azure.StackExchangeRedis/AzureStackExchangeRedisSettings.cs
Outdated
Show resolved
Hide resolved
...spire.Microsoft.Azure.StackExchangeRedis/AspireMicrosoftAzureStackExchangeRedisExtensions.cs
Outdated
Show resolved
Hide resolved
@copilot address the review feedback |
...spire.Microsoft.Azure.StackExchangeRedis/AspireMicrosoftAzureStackExchangeRedisExtensions.cs
Outdated
Show resolved
Hide resolved
…dis config section Co-authored-by: davidfowl <[email protected]>
Addressed all the review feedback in commit efb458c:
|
…0-9ef4-4e67-a68d-5e0a3899cec9
🚀 Dogfood this PR with: curl -fsSL https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 11141 Or
iex "& { $(irm https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 11141" |
builder.AddRedisClientBuilder("redis") | ||
.WithAzureAuthentication() | ||
.WithDistributedCache(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sebastienros @davidfowl @DamianEdwards @mitchdenny - I think this is a better composability API in general.
- The core
AddRedisClientBuilder
API adds the core IConnectionMultiplexer to DI (you can pick keyed or unkeyed). - The extension methods build on that core multiplexer - adding Azure auth (or other auth in the future), Distributed caching, Output caching, etc.
I think this API shape makes much more sense than what we have today. It allows for picking which things are keyed and which aren't. For example, I can have a keyed core Redis connection, but an unkeyed DistributedCache. And vice versa.
Let me know what you think of this API shape. I think this is the route I want to go to make Redis Azure + Distributed/Output caching composable.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.