APS.NET Core : The Perfect Framework?
In 2002, Microsoft released .NET Framework 1.0 as a proprietary software framework for Windows platform. It has been updating the .NET Framework regularly to meet the emerging trends in software development. Microsoft redesigned the core architecture of the .NET Framework to simplify development, testing, and deployment of modern software applications. The company released .NET Core 1.0 on 27th June 2016, along with Entity Framework.
ASP.NET Core is a free and open-source web framework, and the next generation of ASP.NET, developed by Microsoft and the community. It is a modular framework that runs on both the full .NET Framework, on Windows, and the cross-platform .NET Core. The framework is a complete rewrite that unites the previously separate ASP.NET MVC and ASP.NET Web API into a single programming model.
Despite being a new framework, built on a new web stack, it does have a high degree of concept compatibility with ASP.NET MVC. ASP.NET Core applications supports side by side versioning in which different applications, running on the same machine, can target different versions of ASP.NET Core. This is not possible with previous versions of ASP.NET.
.NET Core is a general purpose, modular, cross-platform and open source implementation of the .NET Standard. It contains many of the same APIs as the .NET Framework (but .NET Core is a smaller set) and includes run time, framework, compiler and tools components that support a variety of operating systems and chip targets. The .NET Core implementation was primarily driven by the ASP.NET Core workloads but also by the need and desire to have a more modern implementation. It can be used in device, cloud and embedded/IoT scenarios.
Here, This video will give you complete understanding on future of .NET
Here are the main characteristics of .NET Core:
.NET Core is one of the many projects under the stewardship of the .NET Foundation and is available on GitHub. Having .NET Core as an open source project promotes a more transparent development process and promotes an active and engaged community.
.NET Core provides key functionality to implement the app features you need and reuse this code regardless of your platform target. It currently supports three main operating systems (OS): Windows, Linux and macOS. You can write apps and libraries that run unmodified across supported operating systems.
Whether you’re working in C#, F#, or Visual Basic, your code will run natively on any compatible OS. Different .NET implementations handle the heavy lifting for you:
.NET Core is a cross-platform .NET implementation for websites, servers, and console apps on Windows, Linux, and macOS.
.NET Framework supports websites, services, desktop apps, and more on Windows.
Xamarin/Mono is a .NET implementation for running apps on all the major mobile operating systems.
There are two main ways to deploy your app: framework-dependent deployment or self-contained deployment. With framework-dependent deployment, only your app and third-party dependencies are installed and your app depends on a system-wide version of .NET Core to be present. With self-contained deployment, the .NET Core version used to build your application is also deployed along with your app and third-party dependencies and can run side-by-side with other versions.
.NET Core is modular because it’s released through NuGet in smaller assembly packages. Rather than one large assembly that contains most of the core functionality, .NET Core is made available as smaller feature-centric packages. This enables a more agile development model for us and allows you to optimize your app to include just the NuGet packages you need. The benefits of a smaller app surface area include tighter security, reduced servicing, improved performance, and decreased costs in a pay-for-what-you-use model.
One of the advantages of the .NET Core effort is that many things had to be either rebuilt, or ported from the full .NET Framework. Having all of the internals in flux for a while, combined with the fast release cycles, provided an opportunity to make some performance improvements in code that were almost considered to be “don’t touch, it just works!” before.
Let’s start with SortedSet and its Min and Max implementations. A SortedSet is a collection of objects that is maintained in a sorted order, by leveraging a self-balancing tree structure. Before, getting the Min or Max object from that set required traversing the tree down (or up), calling a delegate for every element and setting the return value as the minimum or maximum to the current element, eventually reaching the top or bottom of the tree. Calling that delegate and passing around objects meant there was quite some overhead involved. Until one developer saw the tree for what is was and removed the unneeded delegate call as it provided no value. His own benchmarks show a 30%-50% performance gain.
When looking through pull requests in the CoreFX lab repository on GitHub, we can see tons of performance improvements that have been made, both by Microsoft and the community. Since .NET Core is open source and you can provide performance fixes too. Most of these are just that fixes to existing classes in .NET. But there is more .NET Core also introduces several new concepts around performance and memory that go beyond just fixing these existing classes.
Top 20 Frameworks in Plaintext
Here on **Web Framework Benchmarks** you can found best **Plaintext response per second** for all different frameworks.
Comparison with .NET Framework
The .NET Framework has been the primary .NET implementation produced by Microsoft during that 17+ year span.
The major differences between .NET Core and the .NET Framework:
· App-models — .NET Core does not support all the .NET Framework app-models, in part because many of them are built on Windows technologies, such as WPF (built on top of DirectX). The console and ASP.NET Core app-models are supported by both .NET Core and .NET Framework.
· APIs — .NET Core contains many of the same, but fewer, APIs as the .NET Framework, and with a different factoring (assembly names are different; type shape differs in key cases). These differences currently typically require changes to port source to .NET Core. .NET Core implements the .NET Standard API, which will grow to include more of the .NET Framework BCL API over time.
· Subsystems — .NET Core implements a subset of the subsystems in the .NET Framework, with the goal of a simpler implementation and programming model. For example, Code Access Security (CAS) is not supported, while reflection is supported.
· Platforms — The .NET Framework supports Windows and Windows Server while .NET Core also supports macOS and Linux.
· Open Source — .NET Core is open source, while a read-only subset of the .NET Framework is open source.
While .NET Core is unique and has significant differences to the .NET Framework and other .NET implementations, it is straightforward to share code, using either source or binary sharing techniques.
You can read complete and more comparison with .NET Framework on this page of Microsoft.
ASP.NET Core Benefits
· A unified story for building web UI and web APIs.
· Integration of modern, client-side frameworks and development workflows.
· A cloud-ready, environment-based configuration system.
· Built-in dependency injection.
· A lightweight, high-performance, and modular HTTP request pipeline.
· Ability to host on IIS, Nginx, Apache, Docker, or self-host in your own process.
· Side-by-side app versioning when targeting .NET Core.
· Tooling that simplifies modern web development.
· Ability to build and run on Windows, macOS, and Linux.
· Open-source and community-focused.
ASP.NET Core ships entirely as NuGet packages. Using NuGet packages allows you to optimize your app to include only the necessary dependencies. In fact, ASP.NET Core 2.x apps targeting .NET Core only require a single NuGet package. The benefits of a smaller app surface area include tighter security, reduced servicing, and improved performance.
Hope this is enough information for you on .NET Core still you need any further assistance on this then you can contact Fuzzy Cloud.
If you found this helpful then please do “Claps” so other can see it too.