Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

7.0.0 Preview 1

Pre-release
Pre-release
Compare
Choose a tag to compare
Loading
@commonsensesoftware commonsensesoftware released this 14 Nov 15:47
· 150 commits to main since this release

This is the first preview release for ASP.NET Core with .NET 7.0 support. No additional work is planned, but there are some breaking changes that can be tried, tested, and discussed before promoting to the official release.

Features

ASP.NET Core

  • Migrate from IProblemDetailsFactory to IProblemDetails
  • Adding grouping support for MapGroup in Minimal APIs

Versioning Minimal APIs still requires a version set which collates configured API versions, but the new MapGroup support makes the setup more natural.

var builder = WebApplication.CreateBuilder( args );

builder.Services.AddApiVersioning();

var app = builder.Build();
var orders = app.MapGroup( "/api/order" ).WithApiVersionSet();

orders.MapGet( "/{id:int}", ( int id ) => new Order() { Id = id, Customer = "John Doe" } ).HasApiVersion( 1.0 );

ASP.NET Core with OData

  • OData does not officially support .NET 7, but it is compatible
    • It is assumed that the eventual support will continue to be forward compatible or bump to 9.0
    • A breaking change in 9.0 could cause complication or require a major version bump for OData packages here

Breaking Changes

  • As previously announced, .NET Core 3.1 has been dropped and is end of life in December 2022
  • Minimal APIs implementation:
    • IVersionedEndpointConventionBuilder and VersionedEndpointConventionBuilder have been removed and are no longer necessary
    • DefaultApiVersionSetBuilderFactory now has a parameterless, default constructor
    • IVersionedEndpointConventionBuilder WithApiVersionSet(IEndpointConventionBuilder, ApiVersionSet) is now TBuilder WithApiVersionSet<TBuilder>(TBuilder, ApiVersionSet) where TBuilder : notnull, IEndpointConventionBuilder
  • ProblemDetails implementation
    • IProblemDetailsFactory has been removed and is supplanted by the built-in IProblemDetailsService
    • The built-in IServiceCollection.AddProblemDetails() must be called to add ProblemDetails
      • This puts the control in your hands
      • Can result in a behavioral breaking change if you omit the setup

If you have additional input or feedback, please provide them in the discussion. This will be the one and only time to discuss it before the release becomes official.

Morty Proxy This is a proxified and sanitized view of the page, visit original site.