![]() |
|
ASP.NET Core 2.2.0-preview2 now available - Printable Version +- Sick Gaming (https://sickgaming.net) +-- Forum: Programming (https://sickgaming.net/forum-76.html) +--- Forum: C#, Visual Basic & .NET (https://sickgaming.net/forum-79.html) +--- Thread: ASP.NET Core 2.2.0-preview2 now available (/thread-86440.html) |
ASP.NET Core 2.2.0-preview2 now available - xSicKxBot - 09-13-2018 ASP.NET Core 2.2.0-preview2 now available Today we’re very happy to announce that the second preview of the next minor release of ASP.NET Core and .NET Core is now available for you to try out. We’ve been working hard on this release over the past months, along with many folks from the community, and it’s now ready for a wider audience to try it out and provide the feedback that will continue to shape the release. How do I get it? You can download the new .NET Core SDK for 2.2.0-preview2 (which includes ASP.NET 2.2.0-preview2) from https://www.microsoft.com/net/download/dotnet-core/2.2 Visual Studio requirements Customers using Visual Studio should also install and use the Preview channel of Visual Studio 2017 (15.9 Preview 2) in addition to the SDK when working with .NET Core 2.2 and ASP.NET Core 2.2 projects. Please note that the Visual Studio preview channel can be installed side-by-side with existing an Visual Studio installation without disrupting your current development environment. Azure App Service Requirements If you are hosting your application on Azure App Service, you can follow these instructions to install the required site extension for hosting your 2.2.0-preview2 applications. Impact to machines Please note that is a preview release and there are likely to be known issues and as-yet-to-be discovered bugs. While the .NET Core SDK and runtime installs are side-by-side, your default SDK will become the latest one. If you run into issues working on existing projects using earlier versions of .NET Core after installing the preview SDK, you can force specific projects to use an earlier installed version of the SDK using a Code: global.jsonWhat’s new in Preview 2 For a full list of changes, bug fixes, and known issues you can read the release notes. SignalR Java Client updated to support Azure SignalR Service The SignalR Java Client, first introduced in preview 1, now has support for the Azure SignalR Service. You can now develop Java and Android applications that connect to a SignalR server using the Azure SignalR Service. To get this new functionality, just update your Maven or Gradle file to reference version 0.1.0-preview2-35174 of the SignalR Client package. Problem Details support In 2.1.0, MVC introduced Code: ProblemDetailsCode: ProblemDetailsCode: ApiControllerAttributeCode: IActionResultCode: ProblemDetailsCode: ProducesResponseTypeCode: ProblemDetailsCode: ProblemDetailsASP.NET Core Module Improvements We’ve introduced a new module ( Code: aspNetCoreModuleV2ASP.NET Core 2.2.0-preview2 or newer projects default to the new in-process hosting model. If you are upgrading from preview1, you will need to add a new project property to your Code: .csprojCode: <PropertyGroup> <TargetFramework>netcoreapp2.2</TargetFramework> <AspNetCoreHostingModel>inprocess</AspNetCoreHostingModel>
</PropertyGroup>Visual Studio 15.9-preview2 adds the ability to switch your hosting model as part of your development-time experience. Hosting in IIS To deploy applications targeting ASP.NET Core 2.2.0-preview2 on servers with IIS, you require a new version of the 2.2 Runtime & Hosting Bundle on the target server. The bundle is available at https://www.microsoft.com/net/download/dotnet-core/2.2. Caveats There are a couple of caveats with the new in-process hosting model: – You are limited to one application per IIS Application Pool. – No support for .NET Framework. The new module is only capable of hosting .NET Core in the IIS process. If you have a ASP.NET Core 2.2 app that’s using the in process hosting model, you can turn it off by setting the Code: <AspNetCoreHostingModel>Code: outofprocessCode: .csprojTemplate Updates We’ve cleaned up the Bootstrap 4 project template work that we started in Preview 1. We’ve also added support to the default Identity UI for using both Bootstrap 3 & 4. For compatibility with existing apps the default Bootstrap version for the default UI is now Bootstrap 3, but you can select which version of Boostrap you want to use when calling Code: AddDefaultUIHealthCheck Improvements There are a few small, but important, changes to health checks in preview2. You can now call Code: AddCheck<T>Code: TCode: IHealthCheckCode: services.AddHealthChecks() .AddCheck<MyHealthCheck>();This will register your health check as a transient service, meaning that each time the health check service is called a new instance will be created. We allow you to register Code: IHealthCheckCode: services.AddHealthChecks();
services.AddSingleton<IHealthCheck, MySingletonCheck>();A scope is created for each invocation of the Code: HealthChecksServiceYou can filter which checks you want to execute when using the middleware or the Code: HealthCheckServiceCode: readyCode: 200 OKCode: liveCode: // The readiness check uses all of the registered health checks (default)
app.UseHealthChecks("/health/ready");
// The liveness check uses an 'identity' health check that always returns healthy
app.UseHealthChecks("/health/live", new HealthCheckOptions()
{ // Exclude all checks, just return a 200. Predicate = (check) => false,
});You might do this if, for example, you are using Kubernetes and want to run a comprehensive set of checks before traffic is sent to your application but otherwise are OK as long as you are reachable and still running. What’s still to come? We are investaging adding a tags mechanism to checks, so that they can be set and filtered on. We also want to provide an Entity Framework specific check that will check whatever database has been configured to be used with your Code: DbContextMigrating an ASP.NET Core 2.1 project to 2.2 To migrate an ASP.NET Core project from 2.1.x to 2.2.0-preview2, open the project’s .csproj file and change the value of the the element to netcoreapp2.2. You do not need to do this if you’re targeting .NET Framework 4.x. Giving Feedback The main purpose of providing previews is to solicit feedback so we can refine and improve the product in time for the final release. Please help provide us feedback by logging issues in the appropriate repository at https://github.com/aspnet or https://github.com/dotnet. We look forward to receiving your feedback! |