ASP.NET Core is a new open-source and cross-platform framework for creating cloud-based Internet applications, such as web applications, IoT applications, and mobile backends.
The first preview of ASP.NET came out almost 15 years ago as part of the .NET Framework. Since then millions of developers have used it to build and run large applications, and over the years we have added and developed many features to it.
ASP.NET Core has a number of architectural modifications that involve a much slimmer and more modular picture.
ASP.NET Core is no longer based on System.Web.dll but is based on a series of granular NuGet packages; This allows you to optimize your application to include only the required NuGet packages. The benefits of a smaller application area include greater security, reduced service, improved performance, and reduced costs in a paid model.
REST multi-platform API, using ASP.NET Core and Visual Studio Code …. Why?
There are many changes that accompany ASP.NET Core:
When ASP.NET Core was released, Microsoft and the .NET community decided to merge the MVC and Web API capabilities; this makes sense since the two have always been very similar.
ASP.NET Web API vs MVC: What Are the Differences?
Before ASP.NET Core, they were very similar; both have followed an MVC model with Action and Controlloer.
The Web API does not have a display engine such as Razor, which is designed to be used for the REST APIs.
Microsoft has promoted the Web API as a framework for creating any type of HTTP service.
It was a great alternative to WCF, SOAP and ASMX web services. It was designed from the beginning with JSON and REST in mind.
MVC is designed for standard web applications with HTML front-end.
The new MVC 6 provided with ASP.NET Core combines the best of MVC Worlds and Web APIs from ASP.NET.
From any controller, you can return a view or object and MVC will take care of serializing it for you.
Several different routing styles allow you to deploy basic MVC web applications or multiple REST APIs.
There are many innovative aspects in .NET Core. For us, however, one of the most exciting aspects of .NET Core is PERFORMANCE:
Collections are the foundation of any application and there are many collections available in .NET libraries.
Net Core introduces some improvements over the overload, such as rationalization operations to allow for better inlining, reduced number of instructions, and so on.
In application code, collections often go hand in hand with integrated LINQ, which has seen even greater improvements.
Many of the LINQ operators have been completely rewritten for .NET Core to reduce the number and size of allocations, reduce algorithmic complexity and generally eliminate unnecessary jobs.
The examples shown so far, of the collections and of LINQ, concern the manipulation of data in memory.
Of course there are many other forms of data manipulation, including the transformations that are strongly related to the CPU. Even in this case, there have been some major improvements to these operations.
Binary serialization is another .NET area that can be quite intense for CPU / data / memory.
BinaryFormatter is a component that was initially left out of .NET Core, but reappears in .NET Core 2.0 to support the existing code that it needs (typically, other forms of serialization are recommended for the new code). The component is very similar to that released in .NET 4.7, with the exception of considerably high performance improvements.
A good amount of effort is applied to optimize and tune the lower levels of the network stack so that you can efficiently build higher-level components.
Such a modification that has a great impact is PR dotnet / corefx # 15141. SocketAsyncEventArgs is at the center of a set of asynchronous operations on Socket and supports a synchronous completion model where asynchronous operations that actually synchronously complete can avoid costs associated with asynchronous completion.