.NET 5 Is The Future Of .NET - What Every .NET Developer Must Know

This article will explain what is not covered in .NET 5 that exists in the .NET Framework and what are the alternative choices.

.Net 5 Is The Future Of .Net - What Every .Net Developers Must Know

Microsoft announced the new .NET 5 (future of .NET) in the Build 2019 conference. .NET 5 will be a single unified platform for building applications that run on all platforms (Windows, Linux) and devices (IoT, Mobile).

If you are a .NET developer currently supporting enterprise applications developed in .NET framework, you need to know how .NET 5 is going to affect your current enterprise applications in the long run. .NET 5 is based on .NET Standard which means not every .NET framework features will be available in .NET 5. Also, there are some technology stacks like web forms, WCF, and WWF that are not porting into .NET 5. In here, we will look into the details of what is not covered in .NET 5 and what are the alternatives. 
 

Technology stacks not coming to .NET 5

ASP.NET Web Forms

ASP.NET Web Forms will not be coming to .NET 5 and Microsoft is currently recommending to move to Blazor which was an experimental project that got promoted to official recently. The other alternative choices are Angular, React, and Vue SPA frameworks if you are good at JavaScript. 

If you are currently using Asp.net MVC as full stack web app, you can continue to use the same stack by using Asp.net Core MVC or the new Razor Pages introduced in .net core 2.0 which may look similar to asp.net web forms to quickly build web form applications without views and controllers. However, if you are developing modern web applications for enterprise, it's better to consider a single page application such as Blazor, Angular or React instead of a traditional web app for providing rich client-side functionality.

WCF (Windows Communication Foundation)

The announcement of "WCF is going to miss the .NET 5 train" surprised many including me. There has been a lot of discussion on GitHub to bring back WCF into the .NET core, but Microsoft decided not to bring it because their initial estimation porting WCF into.NET Core would take three years. (source : DotNetRocks Podcast)

Microsoft is recommending to use gRPC as an alternative which is a modern open-source high-performance RPC framework that can run in any environment. However, unlike WCF, gRPC cannot be hosted in IIS as of today because of HTTP/2 implementation of Http.Sys does not support HTTP response trailing headers which gRPC relies on.

WWF (Windows Workflow Foundation)

Workflow Foundation is not getting ported into .NET Core. Every enterprise application will have some workflow or BPM tools integrated with it. If you used WWF in your application, Microsoft is recommending to look at the unofficial fork of WF runtime for porting into .NET Core.

Technology stacks that are coming to .NET 5
 

 Winforms, WPF & UWP
 
Microsoft is bringing Windows Desktop Packs (winforms , WPF and UWP) to support desktop applications which only works on windows. I wouldn’t expect anyone to use winforms for any new development however this will help to port legacy winforms applications into .NET 5. This doesn’t mean that .Net core architecture is changing. It will still be cross-platform framework but when you are adding desktop packs, it targets to work only on windows. However, porting existing windows desktop application into .Net core will give the additional benefit of Core Runtime and API performance improvements and deployment flexibility
 
 
 

What’s Replaced 

  • EF Core - Entity Framework Core is replacing EF 6 in .Net Core Framework.

  • Asp.net Core - Asp.net is replaced by Asp.net Core. Check the migration guide for porting asp.net application in to asp.net core

  • ASP.NET Core MVC - ASP.NET Core MVC unified ASP.NET MVC and Web API. Check the migration guide for porting asp.net mvc app into asp.net core mvc.

  • MSIX - Microsoft new packaging tool which replaces the old MSI package installer for desktop applications.

  • JsonDocument - New Json Document library from System.Text.Json.JsonDocument API to replace json.net. It is 2-3x times faster than old json.net.

A few other important things to highlight

The latest version of C# 8.0 introduced a lot of new language features including Async Stream, Ranges, Nullable Reference Types, and Pattern Matching, etc.. However, they are going to be available only on .NET Core 3.0 and above which means it is not coming to Legacy .NET Framework, or .NET Core 2.2, 2.1, 1.0. It clearly indicates that “.NET Framework is dead and .NET Core is the future”.

If you are planning to port .NET Framework applications into .NET Core, you will have to analyze your APIs used in your project to see whether it is compatible or not. .NET Portability Analyzer is a tool that helps to analyze and determine how flexible your application is across .NET platforms.

Conclusion

 
As a .NET developer, I am happy to see the future of .NET and the direction it goes into. I no longer need to learn JavaScript for SPA framework because Blazor will do that. I no longer need to learn Python for machine learning because ML.NET will do that. I no longer need to learn Android/Swift because Xamarin will do that. If you know C#, now, you can develop an application that can run anywhere from IoT to Cloud. However, this change is going to affect a lot of enterprise customers who have the product/framework based on WCF and Web Forms.