News

ASP.NET Core, .NET Core, EF Core 1.1 Updates In Preview

The first preview of the next incremental update to ASP.NET Core comes with a slew of new middleware components for speeding up app performance, while updates to .NET Core and Entity Framework Core come with mainly support additions.

A number of significant changes are coming to an incremental update for ASP.NET Core 1.1, which can be tested out in the initial preview release being rolled out this week. Highlights among the laundry list of changes is the addition of several middleware component for URL rewriting, response caching and compression, MVC filters, and providers for Azure App Service logging and Azure Key Vault. .NET Core is also being released, but with less ambitious plans.

One of the middleware components being highlighted is one for URL rewriting functionality. "This allows mapping a public URL space, designed for consumption of your clients, to whatever representation the downstream components of your middleware pipeline require as well as redirecting clients to different URLs based on a pattern," according to Jeffrey T. Fritz, a senior program manager with Microsoft's Developer Outreach Group, in a blog post. Fritz provides two examples, where http://example.com can be rewritten via the middleware to go to a www address, and where another rule can be applied to redirect any http request to an https request. This middleware component "can be configured using IIS standard XML formatted rules, Apache Mod_Rewrite syntax, or some simple C# methods coded into your application," he adds.

Response caching and response compression, used to optimize performance of web pages, are also done via middeleware. Response caching is done by adding Microsoft.AspNetCore.ResponseCaching and the Microsoft.Extensions.Caching.Memory packages to your app's Startup.ConfigureServices method. Response compression uses GZipCompression to compress responses, and it's added via the Microsoft.AspNetCore.ResponseCompression package.

Packages are also available in the preview for allowing apps to use Azure App Service for logging and diagnostics and Azure Key Vault for app configuration via Key Vault secrets. Other features detailed in the blog include:

  • WebListener server
  • View Components as Tag Helpers
  • Middleware as MVC filters
  • Cookie-based TempData provider
  • View compilation
  • Redis and Azure Storage Data Protection Key Repositories

.NET Core 1.1 Preview 1 has less ambitious goals, and is mainly a support release. "Its primary product theme is adding support for new operating system distributions," write Rich Lander, a Microsoft Program Manager with the Common Language Runtime team, in a separate blog post. He lists Linux Mint 18, OpenSUSE 42.1, macOS 10.12, and Windows Server 2016 among the distros, with Fedora 24 coming in a follow-up release later. Lander said that .NET Core 1.1 P1 also includes 1,380 APIs, listed in this document.

Like .NET Core 1.1 Preview 1, Entity Framework Core 1.1 Preview 1 is mainly concerned with stability issues. Even so, there's quite that's being trotted out for testers to check out. Included in this version is an improved EF Core LINQ provider, addition of DbSet.Find() API (used for querying entities based on primary key value), explicit loading of navigation property contents, and the addition of EntityEntry APIs. More details are in this blog post.

About the Author

Michael Domingo is a long-time software publishing veteran, having started up and managed several developer publications for the Clipper compiler, Microsoft Access, and Visual Basic. He's also managed IT pubs for 1105 Media, including Microsoft Certified Professional Magazine and Virtualization Review before landing his current gig as Visual Studio Magazine Editor in Chief. Besides his publishing life, he's a professional photographer, whose work can be found by Googling domingophoto.

comments powered by Disqus

Featured

  • Compare New GitHub Copilot Free Plan for Visual Studio/VS Code to Paid Plans

    The free plan restricts the number of completions, chat requests and access to AI models, being suitable for occasional users and small projects.

  • Diving Deep into .NET MAUI

    Ever since someone figured out that fiddling bits results in source code, developers have sought one codebase for all types of apps on all platforms, with Microsoft's latest attempt to further that effort being .NET MAUI.

  • Copilot AI Boosts Abound in New VS Code v1.96

    Microsoft improved on its new "Copilot Edit" functionality in the latest release of Visual Studio Code, v1.96, its open-source based code editor that has become the most popular in the world according to many surveys.

  • AdaBoost Regression Using C#

    Dr. James McCaffrey from Microsoft Research presents a complete end-to-end demonstration of the AdaBoost.R2 algorithm for regression problems (where the goal is to predict a single numeric value). The implementation follows the original source research paper closely, so you can use it as a guide for customization for specific scenarios.

  • Versioning and Documenting ASP.NET Core Services

    Building an API with ASP.NET Core is only half the job. If your API is going to live more than one release cycle, you're going to need to version it. If you have other people building clients for it, you're going to need to document it.

Subscribe on YouTube