Skip to content

Upgrade distributed caching sample to .NET 10 - #1

Merged
sahansera merged 1 commit into
mainfrom
agent/upgrade-distributed-cache-dotnet-10
Aug 15, 2026
Merged

Upgrade distributed caching sample to .NET 10#1
sahansera merged 1 commit into
mainfrom
agent/upgrade-distributed-cache-dotnet-10

Conversation

@sahansera

Copy link
Copy Markdown
Owner

What changed

  • Upgrade the application from .NET 6 to .NET 10 LTS and pin the SDK.
  • Update Microsoft.Extensions.Caching.StackExchangeRedis to 10.0.11.
  • Enable nullable reference types and modernize the cache, user service, API client, and controller async APIs.
  • Await cache removal before redirecting and add a cache instance prefix.
  • Replace the ReqRes users endpoint with JSONPlaceholder.
  • Pin the local Redis container to redis:8.8.1-alpine and modernize Docker Compose configuration.
  • Update .NET and CodeQL workflows.
  • Add a seven-test suite covering serialization, cache behavior, and HTTP handling.

Why

The existing sample targets unsupported .NET 6. Moving to .NET 10 gives readers a supported LTS baseline and fixes stale runtime, dependency, CI, API, and local Redis instructions.

Validation

  • dotnet restore
  • dotnet build --no-restore --configuration Release
  • dotnet test --no-build --configuration Release --verbosity normal
  • 7 tests passed
  • Build completed with 0 warnings and 0 errors
  • Direct package audit reported no outdated packages

A live Redis integration run was not performed because Docker and Redis were unavailable in the validation environment.

@sahansera
sahansera marked this pull request as ready for review August 15, 2026 12:44
@sahansera
sahansera merged commit ad4e636 into main Aug 15, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant