Skip to content

Conversation

@ChaosEngine
Copy link
Contributor

This pull request upgrades the project from .NET Core 3.1 to .NET 9.0 and migrates authentication from IdentityServer4 to Duende IdentityServer. It also modernizes the GitHub Actions workflows and improves API response serialization and error handling. The most important changes are grouped below by theme.

Framework and Dependency Upgrades:

  • Updated all .csproj files to target net9.0 instead of netcoreapp3.1. This includes Hosts.CookieAuthentication.csproj, Hosts.IdentityServerAuthentication.csproj, Hosts.LosthostAuthentication.csproj, and Hosts.Shared.csproj. [1] [2] [3] [4]
  • Replaced the IdentityServer4 package with Duende.IdentityServer (version 7.4.4) in Hosts.IdentityServerAuthentication.csproj, and updated related namespaces in controllers and startup files. [1] [2] [3]

GitHub Actions Modernization:

  • Updated workflow files to use the latest versions of GitHub Actions, including actions/checkout@v4 and actions/setup-dotnet@v4, and upgraded CodeQL actions to version 3. Also updated the .NET version in the workflow to 9.0.x. [1] [2] [3] [4] [5]

API Serialization and Response Improvements:

  • Added new source-generated JSON serializers in JsonSerializers.cs for various API models, improving performance and consistency in API responses.
  • Refactored API controllers to use strongly-typed anonymous result classes (AnonymousCreatedUser, AnonymousCreatedRole, etc.) for user and role creation endpoints, and to use custom result types like MetaResult for metadata responses. [1] [2] [3] [4]

Error Handling Enhancements:

  • Improved model state error handling by using safe navigation (?.Errors.Clear()) to avoid null reference exceptions in controllers. [1] [2] [3] [4] [5] [6]
  • Enhanced error reporting for user creation by aggregating error messages and returning detailed bad request responses when validation fails.

Miscellaneous API Improvements:

  • Updated serialization logic in PageController to use the new context-based serializer and included additional parameters (TitleNavBarLinkTarget, LoginPath, LogoutPath) in the page model.

These changes collectively modernize the codebase, improve maintainability, and enhance API usability and reliability.

…rable. TitleNavBarLinkTarget: make title link to point to custom target
…rable. TitleNavBarLinkTarget: make title link to point to custom target
rc.2 is failing miserably with impossible RCL error (dotnet/aspnetcore#42629) and requirement of some additional package reference to fix. Crazy but rc.1 works. Tests still failing on Inkball SignalR. Weird.
…ptions/options.JsonSerializerOptions.TypeInfoResolverChain combo
gulp ESM modules migration and rework
fixing the JS code after eslint validation
preparation for further enhancing
Updated all projects to target .NET 9.0, upgrading from .NET Core 3.1.
Replaced IdentityServer4 with Duende IdentityServer due to IdentityServer4's end-of-life.
Updated package references, namespaces, and related code to reflect the migration.
bump: Duende.IdentityServer in some not used project
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant