В сентябре 2019 года выходит новая версия .NET Core 3. Я расскажу о преимуществах .NET Core перед .NET Framework, о том, что нового становится доступным в последней версии .NET Core и о планах Майкрософт по поводу будущего всех .NET фреймворков.
1. Тема доклада
Тема доклада
Тема доклада
KYIV 2019
.NET Core 3 and the future
of .NET platforms
.NET CONFERENCE #1 IN UKRAINE
Olia Gavrysh
2. Тема доклада
Тема доклада
Тема доклада
.NET LEVEL UP
About me
.NET CONFERENCE #1 IN UKRAINE KYIV 2019
Olia Gavrysh
Program Manager
Microsoft, .NET team
twitter: @oliagavrysh
3. Тема доклада
Тема доклада
Тема доклада
.NET LEVEL UP
Agenda
.NET CONFERENCE #1 IN UKRAINE KYIV 2019
1. About .NET Core
2. What’s new in .NET Core 3.0
3. Future of .NET
4. Your platform for building anything
DESKTOP WEB CLOUD MOBILE GAMING IoT AI
.NET
5. Тема доклада
Тема доклада
Тема доклада
.NET LEVEL UP
.NET Core – How it started
.NET CONFERENCE #1 IN UKRAINE KYIV 2019
2002 - .NET Framework 1.0
2016 - .NET Core 1.0
6. .NET LEVEL UP
.NET Core became popular
.NET CONFERENCE #1 IN UKRAINE KYIV 2019
Just a few of our millions of .NET users…
dot.net/customers
7. Тема доклада
Тема доклада
Тема доклада
.NET LEVEL UP
.NET Core Differentiators
.NET CONFERENCE #1 IN UKRAINE KYIV 2018
Light and fast
Deployment flexibility
● side-by-side
● self-contained
● single .exe
● Trimmer
SDK-based project files
Fundamental runtime
improvements
New language features
9. .NET Core 3.0
Released on 9/23
Desktop support for WPF and WinForms
Full-stack web development with C# and Razor
Significant performance improvements
New C# language features for productivity and less errors
https://dotnet.microsoft.com/download/dotnet-core/3.0
10. What’s new in .NET Core
KYIV 2019 .NET CONFERENCE #1 IN UKRAINE
23. Тема доклада
Тема доклада
Тема доклада
Blazor
• Build client-side web UI with .NET instead of JavaScript
• Write reusable web UI components with C# and Razor
• Share .NET code with both the client and the server
• Call into JavaScript libraries & browser APIs as needed
C#
26. Blazor on client or server
https://...
DOM
Razor Components
.NET
WebAssembly
https...
DOM
.NET Core
SignalR
Blazor WebAssembly Blazor Server
Razor Components
.NET
.NET Core 3.0May 2020
27. Blazor on client or server
Blazor WebAssembly Blazor Server
.NET Core 3.0May 2020
28. Тема доклада
Тема доклада
Тема доклада
Get started with Blazor
https://blazor.net
• Install .NET Core 3.0
• Install the Blazor WebAssembly template
• (Windows) Install Visual Studio 2019 16.3
• (Mac/Linux) Install Visual Studio Code with the C# extension
.NET LEVEL UP .NET CONFERENCE #1 IN UKRAINE KYIV 2019
29. Тема доклада
Тема доклада
Тема доклада
The “Awesome Blazor” community
https://aka.ms/awesomeblazor
• Free open-source components & JS interop libraries
• Samples, articles, videos, etc.
• Blazor community on Gitter: https://gitter.im/aspnet/blazor
32. Deployment Flexibility
Side-by-side deployment, self-
contained EXEs
Install machine global or app local
framework
Windows 10
Access modern Windows 10
APIs from WPF and WinForms
Use native Windows 10
controls via XAML islands
Open Source
WPF and WinForms projects
also open source on GitHub
Develop together with open
source community
.NET Core 3.0 for Windows Desktop
34. To port or not to port?
.NET CONFERENCE #1 IN UKRAINE KYIV 2019.NET LEVEL UP
Only
maintenance,
no active
development
Active
development,
new apps
Stay on
Framework
Try Core
35. Тема доклада
Тема доклада
Тема доклада
Porting tool
Try Convert
• https://github.com/dotnet/try-convert
• Will try to convert your old-style project file to the new SDK-style
and retarget your executables to .NET Core 3
36. Microservices
• gRPC
• Worker Service
• Web API’s + Identity
Machine Learning
• Model Builder
• TF integration
• DB loader
IoT
• Raspberry Pi
• Containers
• GPIO pins APIs
Xamarin
• Preview Hot Reload
& Hot Restart
40. July 2019
.NET Core 3.0
RC
Sept 2019
.NET Core 3.0
Nov 2019
.NET Core 3.1
LTS
Nov 2020
.NET 5.0
Nov 2021
.NET 6.0
LTS
Nov 2022
.NET 7.0
Nov 2023
.NET 8.0
LTS
41. .NET 5
INFRASTRUCTURE
.NET STANDARD
.NET – A unified platform
DESKTOP WEB CLOUD MOBILE GAMING IoT AI
WPF
Windows Forms
UWP
ASP.NET Xamarin UnityAzure ARM32
ARM64
ML.NET
.NET for
Apache Spark
<PublishSingleFile>true</PublishSingleFile>
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
<PublishTrimmed>true</PublishTrimmed>
(Фреймворк установлен на более 2 билионов компьютеров)
Blazor is in large part possible thanks to relatively new open web standard called Web Assembly. WA is a bite code for the web. The idea is that if you can compile your code into WA. It can now run in any browser on any platform at near native speed. And we’ve been working for a while now on getting .NET run great on WA. We are building a .NET runtime in WA.
This is how Blazor WA App works. The browser provides core WA support, on top of that we’ve built .NET WA runtime. Then you build your Razor components that could compile into the normal .NET assemblies. They are downloaded with the runtime into the browser and then executed directly in the browser. The browser then sends all it’s UI events to your .NET core, your components run, they render the UI, and Blazor does all the hard work to figure out what exactly changed in the UI. The difference then sent back to the DOM and updated very-very efficiently.
The cool thing about Blazor is that you can host it in many different ways. We’ve just talked about running your app on WA. But alternatively you can also run your Blazor app and host them on the server. Using the same components.
The way Blozor Server App works is your components run on the server, the browser sets up a real-time signalR connection with the server and that’s what it uses to handle and send all the UI events that the user is creating. When a button click occurs, it get’s sent to the server. The corresponding component runs just like it did on a Blazor WA app. Component render. Blazor does all the hard work of calculating the diff. It serialized that diff back to the browser so it can be applied to the DOM.
In Core 3 – support for Server and Blazor WA will be shipped in May next year.
How do you pick between Blazor Server App and Blazor WA App.
I’d like to invite Mads up on stage to show off C# 8.0.
We know we have millions of Windows developers using .NET. So .NET Core has added support for Windows Forms and WPF. This allows you to take advantage of the innovation happening in .NET Core, while still using the UI frameworks you know and love.
And to make deploying, testing and collecting telemetry easy, we’re announcing today the release of .NET Core 3.0 Windows Apps support in App Center.
We’ve added a ton of features to ASP.NET Core in version 3.0 on order to make building resilient microservices easier.
2019 – Introduce .NET 5 – Windows, Mac, Linux, Android, IOS all run .NET Core’s runtime
Same BCL used on all platforms, same runtime used on all platforms
Native code compilation on all platforms, by merging .NET Native and Mono AOT
JIT and AOT Runtime
.NET 5 is the next major version of the .NET Platform that brings technologies from .NET Framework, .NET Core and & Mono runtimes and frameworks together into one .NET platform.
.NET 5 will have one Base Class Library (BCL) that will contain APIs for building any type of application. All .NET workloads are supported with application frameworks including cross-platform web development with ASP.NET, iOS and Android mobile development with Xamarin, Windows Desktop, and cross-platform IoT.
.NET 5 will have both Just-in-Time (JIT) and Ahead-of-Time (AOT) compilation models for the multiple compute and device scenarios it must support. JIT has better performance for server and desktop workloads as well as development environments. AOT has better startup, a small footprint, and is required for mobile and IoT devices.
.NET 5 will also have one unified toolchain supported by new SDK project types, will have a flexible deployment model (Side-by-Side and self-contained EXEs) and continue .NET Core's superior performance for server & cloud workloads.