What’s New in ASP.NET Core 2.2?

Three days ago .NET Core 2.2 has been released. It includes diagnostic improvements to the runtime, support for ARM32 for Windows and Azure Active Directory for SQL Client. The biggest improvements in this release are in ASP.NET Core. Let’s see what’s new in .NET Core 2.2:

Tiered Compilation

Tiered compilation is a feature that enables the runtime to more adaptively use the Just-In-Time (JIT) compiler to get better performance, both at startup and to maximize throughput. It was added as an opt-in feature in .NET Core 2.1 and then was enabled by default in .NET Core 2.2 Preview 2. We decided that we were not quite ready to enable it by default in the final .NET Core 2.2 release, so we switched it back to opt-in, just like .NET Core 2.1. It is enabled by default in .NET Core 3.0 and we expect it to stay in that configuration.

Runtime Events

It is often desirable to monitor runtime services such as the GC, JIT, and ThreadPool of the current process to understand how these services are behaving while running your application. On Windows systems, this is commonly done using ETW and monitoring the ETW events of the current process. While this continues to work well, it is not always easy or possible to use ETW. Whether you’re running in a low-privilege environment or running on Linux or macOS, it may not be possible to use ETW.

Starting with .NET Core 2.2, CoreCLR events can now be consumed using the EventListener class. These events describe the behavior of GC, JIT, ThreadPool, and interop. They are the same events that are exposed as part of the CoreCLR ETW provider on Windows. This allows for applications to consume these events or use a transport mechanism to send them to a telemetry aggregation service.

You can see how to subscribe to events in the following code sample:

internal sealed class SimpleEventListener : EventListener
{
// Called whenever an EventSource is created.
protected override void OnEventSourceCreated(EventSource eventSource)
{
// Watch for the .NET runtime EventSource and enable all of its events.
if (eventSource.Name.Equals(“Microsoft-Windows-DotNETRuntime”))
{
EnableEvents(eventSource, EventLevel.Verbose, (EventKeywords)(-1));
}
}
// Called whenever an event is written.
protected override void OnEventWritten(EventWrittenEventArgs eventData)
{
// Write the contents of the event to the console.
Console.WriteLine($”ThreadID = {eventData.OSThreadId} ID = {eventData.EventId} Name = {eventData.EventName}”);
for (int i = 0; i < eventData.Payload.Count; i++)
{
string payloadString = eventData.Payload[i] != null ? eventData.Payload[i].ToString() : string.Empty;
Console.WriteLine($”\tName = \”{eventData.PayloadNames[i]}\” Value = \”{payloadString}\””);
}
Console.WriteLine(“\n”);
}
}

Support for AccessToken in SqlConnection

The ADO.NET provider for SQL Server, SqlClient, now supports setting the AccessToken property to authenticate SQL Server connections using Azure Active Directory. In order to use the feature, you can obtain the access token value using Active Directory Authentication Library for .NET, contained in the Microsoft.IdentityModel.Clients.ActiveDirectory NuGet package.

The following sample shows how to authenticate SQL Server connections using Azure Active directory:

// get access token using ADAL.NET
var authContext = new AuthenticationContext(authority);
var authResult = await authContext.AcquireTokenAsync(appUri, clientCredential);
// setup connection to SQL Server
var sqlConnection = new SqlConnection(connectionString);
sqlConnection.AccessToken = authResult.AccessToken;
await sqlConnection.OpenAsync();

Injecting code prior to Main

.NET Core now enables injecting code prior to running an application main method via a Startup Hook. Startup hooks make it possible for a host to customize the behavior of applications after they have been deployed, without needing to recompile or change the application.

We expect hosting providers to define custom configuration and policy, including settings that potentially influence load behavior of the main entry point such as the AssemblyLoadContext behavior. The hook could be used to set up tracing or telemetry injection, to set up callbacks for handling, or other environment-dependent behavior. The hook is separate from the entry point, so that user code doesn’t need to be modified.

Windows ARM32

We are adding support for Windows ARM32, similar to the Linux ARM32 support we added in .NET Core 2.1. Windows has had support for ARM32 with Windows IoT Core for some time. As part of the Windows Server 2019 release, ARM32 support was also added for Nanoserver. .NET Core can be used on both Nanoserver and IoT Core.

Docker will be provided for Nanoserver for ARM32 at microsoft/dotnet on Docker Hub.

We ran into a late bug that prevented us from publishing .NET Core builds for Windows ARM32 today. We expect those builds to be in place for .NET Core 2.2.1, in January 2019.

Platform Support

.NET Core 2.2 is supported on the following operating systems:

  • Windows Client: 7, 8.1, 10 (1607+)
  • Windows Server: 2008 R2 SP1+
  • macOS: 10.12+
  • RHEL: 6+
  • Fedora: 26+
  • Ubuntu: 16.04+
  • Debian: 9+
  • SLES: 12+
  • openSUSE: 42.3+
  • Alpine: 3.7+

Chip support follows:

  • x64 on Windows, macOS, and Linux
  • x86 on Windows
  • ARM32 on Linux (Ubuntu 16.04+, Debian 9+)
  • ARM32 on Windows (1809+; available in January)

.NET Core 2.2 includes key improvements for the product. Please try them out and tell us what you think. Also make sure to check out the improvements in ASP.NET Core 2.2 and Entity Framework 2.2.

How to Choose ASP.NET Core 2.2 Hosting Provider?

A reliable web host is a must for all websites and blogs, but it doesn’t have to cost you an arm and a leg. We have always been telling people about this: Not all cheap web host sucks! Some budget web hosts are as good as that web hosting deal you were looking at. And hey, that “awesome” web business idea you have in mind doesn’t need a dedicated hosting yet. You can host it on a shared hosting first and make the switch after it accumulate enough buzz.

Whether you’re a small business, a big brand, or an individual looking to start your first website, this guide will help you choose the best web hosting to get your website live.

  • Eliminated all web hosting companies that were less than three years old or had a negative reputation based on verified online reviews.
  • They should have 24/7 technical support.
  • Web hosting should be simple.
  • Eliminated all remaining web hosts that had misleading pricing, or that didn’t allow you to get up and running at the price mentioned on their homepage or pricing page
  • Eliminated web hosts with slow servers (that took longer than 1 second to load a basic website)
  • Choose a reputable web host with uptime in this ballpark, you’ll be in safe hands.

The Best European ASP.NET Core 2.2 Cloud Hosting

HostForLIFEASP.NET – Company Background

In the year 2008, a group of IT professionals pulled their resources together and formed HostForLIFEASP.NET, the provider which focus on Windows ASP.NET hosting technology, this date, HostForLIFEASP.NET remains privately held.

It owns a big advantage that is short distance between its offices and the datacenter. HostForLIFEASP.NET has many data centers in Europe. This is big advantages for customers in Europe. Customer can choose their Paris, London, Frankfurt, Amsterdam, and also their newest Italy datacenters if you register their ASP.NET hosting plan.

Small businesses and private individuals form the core of its client base in the ASP.NET hosting business, with about 150,000 websites hosted through its facilities.

Feature

HostForLIFEASP.NET has practical experience in offering proficient ASP.NET hosting arrangements. As Microsoft Golden Hosting Partner, HostForLIFEASP.NET dependably could convey the most recent Microsoft innovation to its clients sooner than its rivals.

In its hosting arrangement, its client will get:

  • Windows Server 2012 and Windows Server 2016 platform, clients can choose the fancied one when subscribing to the administration
  • MSSQL 2012, MSSQL 2014, MSSQL 2016, and MySQL 5
  • ASP.NET 2.0, 3.5, 4.5, 4.7.x, Core 2.2, PHP 5.x, PHP 7, II 8.x,and II 7.x,
  • Full IIS trust level, ASP.NET AJAX, ASP.NET MVC 6, WebSockets, SignalR and dedicated application pool
  • Diverse ASP.NET parts like ASP.NET ReportViewer Control, ASP.NET Charting Control and others are accessible for use by all clients at no cost
  • A Plesk control panel, making the administration and alter of domain, databases, files, web traffic log, IIS settings, or consent convenience.

In the interim, fundamental hosting assets incorporated into this comprehensive arrangement are unlimited disk space, unlimited bandwidth, unlimited dmain, and FTP over SSL.

Concerning the solid association with Microsoft, another awesome thing to be a HostForLIFEASP.NET client is that they could get the chance to attempt beta arrival of new Microsoft items and turn into the primary man to try out the future Microsoft innovation.

Pricing

HostForLIFEASP.NET releases four plans called Classic, Budget, Economy and Business at the prices of €3.49/month, €5.50/month, €8.00/month and €10.99/month if you choose annual payment method. Three billing cycles with different prices are available in HostForLIFE.eu best ASP.NET hosting package. You can choose between 3-months, 1-year and 3-years payment methods.

All these packages are made available from its array of servers that are exclusively Windows-based. Its services also extend to e-commerce solution, for customers who look for extra help in setting up their online shops.

Classic Plan

If you’re new to ASP.NET, or if you plan on hosting your ASP.NET Core site (or other small site) then HostForLIFE’s Classic plan just might be right for you. Designed for lower traffic websites, this plan allows you to host your simple ASP.NET site that gets around 10,000 hits per month. It’s perfect for just starting out.

Budget Plan

As your site grows upgrade to the Budget plan. Suited for moderate traffic, this HostForLIFE plan allows you to host an unlimited number of websites so you can host your own network of sites (so long as the traffic is just around  25,000 per month) or just one popular one. Plus, when you upgrade you get added features including the double MSSQL databases, Double MSSQL space, more RAM usage

Economy Plan

If you site just keeps getting bigger (since you’re super cool), or if you’re looking for solid hosting for your business website, the Economy plan is a great option. With premium features including 1-click staging, premium backups, unlimited professional website restorations from HostForLIFEASP.NET is one of the best plans they offer.

Business Plan

This is the best plan for ASP.NET site. If you are developer or business plan that requires high memory usage or you have many visitors to your site, then Business plan is the best plan for your ASP.NET site. This plan comes with premium backup, free checking virus every month, unlimited professional website restorations, free cloudflare service, and very suitable for ecommerce site.

Do We Recommend HostForLIFEASP.NET?

To put it plainly, HostForLIFEASP.NET is Microsoft-perceived ASP.NET Core 2.2 hosting and Windows Server 2016 pioneer, which could convey the best understanding to all ASP.NET designers and entrepreneurs. What’s more, we unequivocally prescribe HostForLIFEASP.NET hosting administration.

To know more about HostForLIFEASP.NET, please visit www.HostForLIFEASP.NET

Rate this post