SlideShare a Scribd company logo
9
Most read
19
Most read
21
Most read
.NET Core
How to migrate and write new code for .NET Core
Bertrand Le Roy
▪ Senior Program Manager on .NET Core
▪ One of the founders of Orchard
▪ http://weblogs.asp.net/bleroy
▪ https://blogs.msdn.microsoft.com/dotnet/tag/week-in-net/
▪ https://www.youtube.com/channel/UCvtT19MZW8dq5Wwfu6B0oxw
Objectives
▪ What’s .NET Core and when to use it (or not)
▪ How to create a new library, ASP.NET, or console application
▪ How to port existing code
Innovation Any platformOpenness
.NET Core
ASP.NET 5
.NET Core ≠ .NET Framework
.NET Framework 4.6
▪ .NET implementation for any scenario on Windows with comprehensive library
support
.NET Core
▪ Modular and smaller implementation of .NET
▪ Cross-platform
▪ App-level isolation
▪ Built in the open
▪ Optimized for specific workloads
▪ Built for the next ten years of software development
Next gen JIT (RyuJIT)
SIMD
Runtime
Components Compilers
Languages innovation
.NET Compiler Platform
.NET Core 5 Libraries
.NET Framework 4.6 Libraries
NuGet packages
.NET Framework 4.6 .NET Core
What’s common, and what’s not?
What’s not supported?
▪ WPF
▪ Winforms
▪ WebForms
▪ Binary serialization…
▪ Anything Windows-specific: registry, ACLs, perf counters, etc.
Significant change: Reflection
foo.GetType() → foo.GetType().GetTypeInfo()
API Portability resources
▪ Portability analyzer VS extension
▪ https://github.com/Microsoft/dotnet-apiport/releases
▪ http://dotnetstatus.azurewebsites.net/
▪ https://packagesearch.azurewebsites.net/
▪ http://forums.dotnetfoundation.org/
▪ https://gitter.im/dotnet/corefx
▪ https://dotnet.github.io/porting *
Managing expectations
▪ This is very much a new platform with a known flavor
▪ There is a cost to migration
▪ There are things to learn
▪ Not all projects can or should migrate
Should I migrate my project?
Cannot:
▪ WPF, WinForms, unless UWP
▪ ASP.NET WebForms
Should (absolutely):
▪ General purpose libraries
Should (maybe):
▪ ASP.NET MVC
▪ Micro-services
▪ Console apps
▪ Rewrite
▪ Talent expertise on Linux
DEMO
Porting FluentPath
Dependencies
▪ Most fundamental libraries first: test frameworks, tooling, data access, JSON,
logging, IoC, etc.
▪ Go to the source, ask the author
▪ Offer to help, or fork
▪ Switch to another Core-compatible library
▪ DIY
Testing
▪ xUnit was first, now NUnit, MsTest
▪ Secondary test libraries (mocking, functional testing, etc.) in progress
Debugging
▪ On Windows: Visual Studio
▪ Everywhere: VS Code
Tooling
Your choice of tool, on your choice platform
▪ Visual Studio on Windows
▪ Visual Studio Code on Mac, Linux, or Windows
▪ vi or emacs with OmniSharp
▪ etc.
.NET CLI replaces DNX, DNVM, DNU
▪ dotnet new
▪ dotnet restore
▪ dotnet run
▪ dotnet build
▪ dotnet build –native
▪ dotnet dosomethingcool
DEMO
Creating a new application
Q&A

More Related Content

What's hot (20)

PPT
ASP.NET MVC Presentation
ivpol
 
PPTX
ASP.NET Core MVC + Web API with Overview
Shahed Chowdhuri
 
PDF
Dot Net Core
Amir Barylko
 
PPTX
Introduction to .NET Core
Marco Parenzan
 
PDF
Spring MVC Framework
Hùng Nguyễn Huy
 
PPTX
Introduction to Spring Framework
Serhat Can
 
PDF
React js
Rajesh Kolla
 
PDF
Model View Controller (MVC)
Javier Antonio Humarán Peñuñuri
 
PPTX
Web api
Sudhakar Sharma
 
PPTX
Reactjs
Neha Sharma
 
PPTX
ASP.NET Core: The best of the new bits
Ken Cenerelli
 
PDF
Basics of React Hooks.pptx.pdf
Knoldus Inc.
 
PDF
Spring Boot
Jaran Flaath
 
PDF
.NET Core, ASP.NET Core Course, Session 6
Amin Mesbahi
 
PPTX
Jenkins Pipeline Tutorial | Jenkins Build And Delivery Pipeline | Jenkins Tut...
Simplilearn
 
PPTX
React JS - A quick introduction tutorial
Mohammed Fazuluddin
 
PPTX
Introduction to Node js
Akshay Mathur
 
PPTX
Spring boot
Gyanendra Yadav
 
PDF
React JS - Introduction
Sergey Romaneko
 
ASP.NET MVC Presentation
ivpol
 
ASP.NET Core MVC + Web API with Overview
Shahed Chowdhuri
 
Dot Net Core
Amir Barylko
 
Introduction to .NET Core
Marco Parenzan
 
Spring MVC Framework
Hùng Nguyễn Huy
 
Introduction to Spring Framework
Serhat Can
 
React js
Rajesh Kolla
 
Model View Controller (MVC)
Javier Antonio Humarán Peñuñuri
 
Reactjs
Neha Sharma
 
ASP.NET Core: The best of the new bits
Ken Cenerelli
 
Basics of React Hooks.pptx.pdf
Knoldus Inc.
 
Spring Boot
Jaran Flaath
 
.NET Core, ASP.NET Core Course, Session 6
Amin Mesbahi
 
Jenkins Pipeline Tutorial | Jenkins Build And Delivery Pipeline | Jenkins Tut...
Simplilearn
 
React JS - A quick introduction tutorial
Mohammed Fazuluddin
 
Introduction to Node js
Akshay Mathur
 
Spring boot
Gyanendra Yadav
 
React JS - Introduction
Sergey Romaneko
 

Viewers also liked (20)

PPTX
ASP.NET Core 1.0 Overview
Shahed Chowdhuri
 
PPTX
Getting Started with ASP.net Core 1.0
joescars
 
PPTX
ASP.NET Core MVC + Web API with Overview
Shahed Chowdhuri
 
PPTX
ASP.NET Core 1.0 Overview: Post-RC2
Shahed Chowdhuri
 
PPTX
ASP.NET Core 1.0 Overview: Pre-RC2
Shahed Chowdhuri
 
PDF
Getting Started with ASP.NET Core 1.0 (formerly ASP.NET 5)
Arrow Consulting & Design
 
PPTX
.Net Core - not your daddy's dotnet
Rick van den Bosch
 
PDF
Getting Started .NET Core
Yuta Matsumura
 
PPTX
Apresentação do Projeto de Bloco Arquitetura .NET
Pedro Modrach
 
PPT
Unitat 1. El nostre planeta. 1rESO
csantan2
 
PDF
.Net standard 2.0
Scott Golightly
 
PPTX
.Net Core
Bohdan Pashkovskyi
 
PPTX
Microsoft dot net framework
Ashish Verma
 
PPTX
ASP.NET Core
Maurice De Beijer [MVP]
 
PPT
Learning .NET Attributes
Pooja Gaikwad
 
PPTX
.NET Core
Mariano Sánchez
 
PPTX
Windows a dobozban, avagy IoT fejlesztés C#-ban
György Balássy
 
PPTX
IIS 7.5 webszerver újdonságok
György Balássy
 
PPTX
Enterprise Developer Meetup bevezető (2015.01.28.)
György Balássy
 
PPTX
XXI. századi szoftverfejlesztés
György Balássy
 
ASP.NET Core 1.0 Overview
Shahed Chowdhuri
 
Getting Started with ASP.net Core 1.0
joescars
 
ASP.NET Core MVC + Web API with Overview
Shahed Chowdhuri
 
ASP.NET Core 1.0 Overview: Post-RC2
Shahed Chowdhuri
 
ASP.NET Core 1.0 Overview: Pre-RC2
Shahed Chowdhuri
 
Getting Started with ASP.NET Core 1.0 (formerly ASP.NET 5)
Arrow Consulting & Design
 
.Net Core - not your daddy's dotnet
Rick van den Bosch
 
Getting Started .NET Core
Yuta Matsumura
 
Apresentação do Projeto de Bloco Arquitetura .NET
Pedro Modrach
 
Unitat 1. El nostre planeta. 1rESO
csantan2
 
.Net standard 2.0
Scott Golightly
 
Microsoft dot net framework
Ashish Verma
 
Learning .NET Attributes
Pooja Gaikwad
 
.NET Core
Mariano Sánchez
 
Windows a dobozban, avagy IoT fejlesztés C#-ban
György Balássy
 
IIS 7.5 webszerver újdonságok
György Balássy
 
Enterprise Developer Meetup bevezető (2015.01.28.)
György Balássy
 
XXI. századi szoftverfejlesztés
György Balássy
 
Ad

Similar to .Net Core (20)

PPTX
Dotnet on linux
Ebram Tharwat
 
PDF
OSS SW Basics Lecture 03: Fundamental parts of open-source projects
Jeongkyu Shin
 
PPTX
ASP.NET 5 - Microsoft's Web development platform reimagined
Alex Thissen
 
PPTX
.NET - The Current Spectrum
Rasik Bihari Tiwari
 
PPTX
Porting Projects to .NET 5
Immo Landwerth
 
PDF
Business Apps with the Universal Windows Platform
Christian Nagel
 
PPTX
Getting Started with ASP.NET vNext
Lohith Goudagere Nagaraj
 
PDF
August Webinar - Water Cooler Talks: A Look into a Developer's Workbench
Howard Greenberg
 
PDF
Introducing ASP.NET vNext – The Future of .NET on the Server | FalafelCON 2014
FalafelSoftware
 
PPT
Visual studio 2015 and .net core 5 – get ready to rumble
Tadeusz Balcer
 
PDF
.NET Core, ASP.NET Core Course, Session 1
Amin Mesbahi
 
PPT
Buildingwebapplicationswith.net
Kolagani Veera
 
PDF
Pottnet MeetUp Essen - ASP.Net Core
Malte Lantin
 
PDF
Pottnet Meetup Essen - ASP.Net Core
Malte Lantin
 
PPTX
Deploy a Website in Azure using ARM Templates
Pratik Khasnabis
 
PPTX
Introducing ASP.NET vNext - A tour of the new ASP.NET platform
Jeffrey T. Fritz
 
PDF
AWS Innovate: Moving Microsoft .Net applications one container at a time - Da...
Amazon Web Services Korea
 
PDF
PaaS options for .NET
Slawomir Dorzak
 
PDF
Infrastructure as code with Terraform
Sam Bashton
 
PDF
DOT NET TRaining
sunil kumar
 
Dotnet on linux
Ebram Tharwat
 
OSS SW Basics Lecture 03: Fundamental parts of open-source projects
Jeongkyu Shin
 
ASP.NET 5 - Microsoft's Web development platform reimagined
Alex Thissen
 
.NET - The Current Spectrum
Rasik Bihari Tiwari
 
Porting Projects to .NET 5
Immo Landwerth
 
Business Apps with the Universal Windows Platform
Christian Nagel
 
Getting Started with ASP.NET vNext
Lohith Goudagere Nagaraj
 
August Webinar - Water Cooler Talks: A Look into a Developer's Workbench
Howard Greenberg
 
Introducing ASP.NET vNext – The Future of .NET on the Server | FalafelCON 2014
FalafelSoftware
 
Visual studio 2015 and .net core 5 – get ready to rumble
Tadeusz Balcer
 
.NET Core, ASP.NET Core Course, Session 1
Amin Mesbahi
 
Buildingwebapplicationswith.net
Kolagani Veera
 
Pottnet MeetUp Essen - ASP.Net Core
Malte Lantin
 
Pottnet Meetup Essen - ASP.Net Core
Malte Lantin
 
Deploy a Website in Azure using ARM Templates
Pratik Khasnabis
 
Introducing ASP.NET vNext - A tour of the new ASP.NET platform
Jeffrey T. Fritz
 
AWS Innovate: Moving Microsoft .Net applications one container at a time - Da...
Amazon Web Services Korea
 
PaaS options for .NET
Slawomir Dorzak
 
Infrastructure as code with Terraform
Sam Bashton
 
DOT NET TRaining
sunil kumar
 
Ad

More from Bertrand Le Roy (8)

PPTX
Next .NET and C#
Bertrand Le Roy
 
PPTX
Orchard 2... and why you should care
Bertrand Le Roy
 
PPTX
C# Today and Tomorrow
Bertrand Le Roy
 
PPTX
.NET Foundation, Future of .NET and C#
Bertrand Le Roy
 
PPTX
Orchard Harvest Keynote 2015 - the CMS of the future
Bertrand Le Roy
 
PPTX
Best kept Orchard recipes - Orchard Harvest Amsterdam 2013
Bertrand Le Roy
 
PPTX
Commerce - Orchard Harvest Amsterdam 2013
Bertrand Le Roy
 
PPTX
Orchard Harvest Amsterdam 2013 Keynote
Bertrand Le Roy
 
Next .NET and C#
Bertrand Le Roy
 
Orchard 2... and why you should care
Bertrand Le Roy
 
C# Today and Tomorrow
Bertrand Le Roy
 
.NET Foundation, Future of .NET and C#
Bertrand Le Roy
 
Orchard Harvest Keynote 2015 - the CMS of the future
Bertrand Le Roy
 
Best kept Orchard recipes - Orchard Harvest Amsterdam 2013
Bertrand Le Roy
 
Commerce - Orchard Harvest Amsterdam 2013
Bertrand Le Roy
 
Orchard Harvest Amsterdam 2013 Keynote
Bertrand Le Roy
 

Recently uploaded (20)

PDF
Unified_Cloud_Comm_Presentation anil singh ppt
anilsingh298751
 
PPTX
Pharmaceuticals and fine chemicals.pptxx
jaypa242004
 
PPTX
Day2 B2 Best.pptx
helenjenefa1
 
PDF
Book.pdf01_Intro.ppt algorithm for preperation stu used
archu26
 
PPTX
Server Side Web Development Unit 1 of Nodejs.pptx
sneha852132
 
PDF
PORTFOLIO Golam Kibria Khan — architect with a passion for thoughtful design...
MasumKhan59
 
PDF
Ethics and Trustworthy AI in Healthcare – Governing Sensitive Data, Profiling...
AlqualsaDIResearchGr
 
DOCX
CS-802 (A) BDH Lab manual IPS Academy Indore
thegodhimself05
 
PPTX
Shinkawa Proposal to meet Vibration API670.pptx
AchmadBashori2
 
PDF
ARC--BUILDING-UTILITIES-2-PART-2 (1).pdf
IzzyBaniquedBusto
 
PPTX
美国电子版毕业证南卡罗莱纳大学上州分校水印成绩单USC学费发票定做学位证书编号怎么查
Taqyea
 
PPTX
Green Building & Energy Conservation ppt
Sagar Sarangi
 
PDF
Pressure Measurement training for engineers and Technicians
AIESOLUTIONS
 
PPTX
265587293-NFPA 101 Life safety code-PPT-1.pptx
chandermwason
 
PDF
GTU Civil Engineering All Semester Syllabus.pdf
Vimal Bhojani
 
PDF
Introduction to Productivity and Quality
মোঃ ফুরকান উদ্দিন জুয়েল
 
PDF
6th International Conference on Machine Learning Techniques and Data Science ...
ijistjournal
 
DOC
MRRS Strength and Durability of Concrete
CivilMythili
 
PPTX
artificial intelligence applications in Geomatics
NawrasShatnawi1
 
PDF
Statistical Data Analysis Using SPSS Software
shrikrishna kesharwani
 
Unified_Cloud_Comm_Presentation anil singh ppt
anilsingh298751
 
Pharmaceuticals and fine chemicals.pptxx
jaypa242004
 
Day2 B2 Best.pptx
helenjenefa1
 
Book.pdf01_Intro.ppt algorithm for preperation stu used
archu26
 
Server Side Web Development Unit 1 of Nodejs.pptx
sneha852132
 
PORTFOLIO Golam Kibria Khan — architect with a passion for thoughtful design...
MasumKhan59
 
Ethics and Trustworthy AI in Healthcare – Governing Sensitive Data, Profiling...
AlqualsaDIResearchGr
 
CS-802 (A) BDH Lab manual IPS Academy Indore
thegodhimself05
 
Shinkawa Proposal to meet Vibration API670.pptx
AchmadBashori2
 
ARC--BUILDING-UTILITIES-2-PART-2 (1).pdf
IzzyBaniquedBusto
 
美国电子版毕业证南卡罗莱纳大学上州分校水印成绩单USC学费发票定做学位证书编号怎么查
Taqyea
 
Green Building & Energy Conservation ppt
Sagar Sarangi
 
Pressure Measurement training for engineers and Technicians
AIESOLUTIONS
 
265587293-NFPA 101 Life safety code-PPT-1.pptx
chandermwason
 
GTU Civil Engineering All Semester Syllabus.pdf
Vimal Bhojani
 
Introduction to Productivity and Quality
মোঃ ফুরকান উদ্দিন জুয়েল
 
6th International Conference on Machine Learning Techniques and Data Science ...
ijistjournal
 
MRRS Strength and Durability of Concrete
CivilMythili
 
artificial intelligence applications in Geomatics
NawrasShatnawi1
 
Statistical Data Analysis Using SPSS Software
shrikrishna kesharwani
 

.Net Core

  • 1. .NET Core How to migrate and write new code for .NET Core
  • 2. Bertrand Le Roy ▪ Senior Program Manager on .NET Core ▪ One of the founders of Orchard ▪ http://weblogs.asp.net/bleroy ▪ https://blogs.msdn.microsoft.com/dotnet/tag/week-in-net/ ▪ https://www.youtube.com/channel/UCvtT19MZW8dq5Wwfu6B0oxw
  • 3. Objectives ▪ What’s .NET Core and when to use it (or not) ▪ How to create a new library, ASP.NET, or console application ▪ How to port existing code
  • 5. .NET Core ≠ .NET Framework
  • 6. .NET Framework 4.6 ▪ .NET implementation for any scenario on Windows with comprehensive library support
  • 7. .NET Core ▪ Modular and smaller implementation of .NET ▪ Cross-platform ▪ App-level isolation ▪ Built in the open ▪ Optimized for specific workloads ▪ Built for the next ten years of software development
  • 8. Next gen JIT (RyuJIT) SIMD Runtime Components Compilers Languages innovation .NET Compiler Platform .NET Core 5 Libraries .NET Framework 4.6 Libraries NuGet packages .NET Framework 4.6 .NET Core What’s common, and what’s not?
  • 9. What’s not supported? ▪ WPF ▪ Winforms ▪ WebForms ▪ Binary serialization… ▪ Anything Windows-specific: registry, ACLs, perf counters, etc.
  • 10. Significant change: Reflection foo.GetType() → foo.GetType().GetTypeInfo()
  • 11. API Portability resources ▪ Portability analyzer VS extension ▪ https://github.com/Microsoft/dotnet-apiport/releases ▪ http://dotnetstatus.azurewebsites.net/ ▪ https://packagesearch.azurewebsites.net/ ▪ http://forums.dotnetfoundation.org/ ▪ https://gitter.im/dotnet/corefx ▪ https://dotnet.github.io/porting *
  • 12. Managing expectations ▪ This is very much a new platform with a known flavor ▪ There is a cost to migration ▪ There are things to learn ▪ Not all projects can or should migrate
  • 13. Should I migrate my project? Cannot: ▪ WPF, WinForms, unless UWP ▪ ASP.NET WebForms Should (absolutely): ▪ General purpose libraries Should (maybe): ▪ ASP.NET MVC ▪ Micro-services ▪ Console apps ▪ Rewrite ▪ Talent expertise on Linux
  • 15. Dependencies ▪ Most fundamental libraries first: test frameworks, tooling, data access, JSON, logging, IoC, etc. ▪ Go to the source, ask the author ▪ Offer to help, or fork ▪ Switch to another Core-compatible library ▪ DIY
  • 16. Testing ▪ xUnit was first, now NUnit, MsTest ▪ Secondary test libraries (mocking, functional testing, etc.) in progress
  • 17. Debugging ▪ On Windows: Visual Studio ▪ Everywhere: VS Code
  • 18. Tooling Your choice of tool, on your choice platform ▪ Visual Studio on Windows ▪ Visual Studio Code on Mac, Linux, or Windows ▪ vi or emacs with OmniSharp ▪ etc.
  • 19. .NET CLI replaces DNX, DNVM, DNU ▪ dotnet new ▪ dotnet restore ▪ dotnet run ▪ dotnet build ▪ dotnet build –native ▪ dotnet dosomethingcool
  • 20. DEMO Creating a new application
  • 21. Q&A

Editor's Notes

  • #5: Innovation: Innovate and deliver much faster Prompt audience about their favorite pas innovation from .NET. Quote Roslyn, Linq, async/await, generic implementation. Openness enriches the platform and the community On any device and platform
  • #6: Core is different from .NET Framework, and Core is also not .NET Fx 5.
  • #8: Open: not just the source: design documents, code reviews, experiments, roadmaps Open contributions with quality standards, in particular in terms of security.
  • #10: Windows-specific: at least for now, as platform-specific libraries will appear.
  • #15: WPF, WinForms, even if the application isn’t going cross-platform, stay on .Net Fx. A migration to UWP is possible, but that means a rewrite of the UI in addition to the Core migration. ASP.NET WebForms applications should remain on .NET Fx. On the other hand, MVC applications, micro-services, console apps, and anything that can benefit in being deployed cross-platform, especially using containers, is an excellent choice. General purpose libraries should definitely be ported and support both Core and Fx.
  • #16: Open VS, go to Tools / Extensions and updates, show the portability analyzer is there. Open FluentPath solution, right-click Fluent.IO, analyze/analyze portability -> 100% Do the same on Fluent.IO.Windows -> 91.67%, and a detailed list of failures. Those APIs are simply not supported because Windows-specific. Do the same with the NonPortableLibrary solution -> 97.22%. Show how the IsAbstract recommended change is to go through GetTypeInfo(). Show the html file on disk. From the NonPortableLibrary root folder, do …\apiport.exe listOutputFormats; …\apiport.exe analyze –f .\bin\Debug –r Excel –o report.xlsx. Show the Excel report with its two tabs. Go to http://dotnetstatus.azurewebsites.net, look for IsAbstract, show the Type and TypeInfo entries. (That’s an anomaly due to the fact that TypeInfo on .NET Framework derives from Type. Most of the TypeInfo thus show up as defined by the base.) Go to https://packagesearch.azurewebsites.net, look for IsAbstract, show the result for System.Reflection.TypeInfo, show package name and version number.
  • #17: Open the Nuget Package Explorer.+3. Click "Open a package from online feed". (screenshot)+4. Search for the name of a package in the search field and hit enter. (screenshot of result)+5. Expand the "lib" folder and look for a target subfolder that is compatible with .NET Core. (screenshot)++ TODO: Something with `dnxcore50`, `dotnet`, `netstandardlib`, ... is what you're looking for.+ + If there isn't a target subfolder compatible with .NET Core, the dependency will not run on .NET Core.
  • #20: Mention JetBrains Project Rider
  • #21: Dotnet build, in the case of an app, generates runnable assets by copying an executable host.
  • #22: Create new portable library from VS by following the script http://aka.ms/port2core Create new command-line app from CLI: show https://github.com/dotnet/cli/blob/master/Documentation/intro-to-cli.md