Tarabica 2019 - Migration from ASP.NET MVC to ASP.NET Core

Miroslav Popovic
Miroslav PopovicTechnical Lead at Seavus
Tarabica 2019 - Migration from ASP.NET MVC to ASP.NET Core
tweet #tarabica19
Migration from ASP.NET MVC to ASP.NET Core
Belgrade
May 25th, 2019
Miroslav Popović
Technical Lead, Seavus Group
https://miroslavpopovic.com
@miroslavpopovic
Sponzori Generalni sponzor
Srebrni sponzori
Tehnički sponzori
tweet #tarabica19
Bronzani sponzor
Partner konferencije
tweet #tarabica19
Introduction
A bit of history
• .NET Framework 1.0
• ASP.NET 1.0
• ASP.NET 2.0
• ASP.NET MVC
• ASP.NET WebAPI
• ASP.NET Core & .NET Core
tweet #tarabica19
Why migrate?
• Old platform, no longer improved
• .NET Framework 4.8 is the last version
• Performance is not that great
• System.Web dependency
• Windows only
• Using it with containers is harder
• Running multiple side-by-side installations is harder
• Configuration is harder
• Doesn’t play well with modern web
tweet #tarabica19
Why not stay?
tweet #tarabica19
ASP.NET Core benefits
• Multiplatform
• Open source for real
• Performance
• New configuration system
• Easy to use with Docker
tweet #tarabica19
ASP.NET Core benefits (cont.)
• Side by side with another app on different .NET Core
• Joined MVC and WebAPI
• Excellent for REST APIs
• Plays great with modern web tools
• Part of the .NET future
tweet #tarabica19
ASP.NET Core benefits (cont.)
tweet #tarabica19
.NET Standard
tweet #tarabica19
tweet #tarabica19
Migration from ASP.NET MVC
Migration process
• Latest version of .NET Framework (at least 4.6.2)
• Analyze your solution with .NET Portability Analyzer
• Migrate non-ASP.NET projects to .NET Standard
• Create new ASP.NET Core 2.1+ (or 3.0) project
• Migrate startup code and initialization
• Migrate static files, configure bundles
• Migrate views and actions
tweet #tarabica19
Project organization
tweet #tarabica19
Project files
tweet #tarabica19
Middleware pipeline
tweet #tarabica19
Startup
tweet #tarabica19
Razor changes
tweet #tarabica19
Tag helpers and client libs
tweet #tarabica19
Web Components
• Dynamic navigation menus
• Tag cloud (where it queries the database)
• Login panel
• Shopping cart
• Recently published articles
• Sidebar content on a typical blog
tweet #tarabica19
Web API
• Same controllers as for MVC
• Configuration in Startup
• [ApiController]
• ActionResult<T>
• Swagger / Open API specification
• HTTPS by default
• API conventions
• API analyzers
tweet #tarabica19
tweet #tarabica19
Potential problems
.NET Core & .NET Standard
• Not all APIs are migrated to Core
• .NET Portability Analyzer
• Registry access
• WCF servers
• AppDomain
• Remoting
tweet #tarabica19
Database access
• Depends on DB library used
• Direct ADO.NET access
• Micro ORMs
• NHibernate
• Entity Framework
tweet #tarabica19
Entity Framework Core
• Different than EF6.x
• Migrations
• Still not feature-ready
• Entity Framework 6.3 migrated to .NET Core 3.0
tweet #tarabica19
ASP.NET Identity
• Database changes
• View changes
• Scaffolding
tweet #tarabica19
tweet #tarabica19
Closing words
When not to migrate?
• ASP.NET Web Forms
• ASP.NET MVC Web Forms
• Missing APIs
• Old dependencies
• …
• Rewriting parts of solution
tweet #tarabica19
ASP.NET Core future
• .NET Core 3.0 - September 2019.
• Performance++
• Server-side Blazor
• Endpoint routing improvements
• SPA template improvements
• …
• Client-side Blazor
tweet #tarabica19
Current performance
tweet #tarabica19
ASP.NET Core: Saturating 10GbE at 7+ million request/s - https://bit.ly/2Gns2Dq
Future performance
tweet #tarabica19
https://aka.ms/aspnet/benchmarks
6 minutes, 64 connections, 120.000.000 requests
.NET 5!
tweet #tarabica19
Are you convinced?
• Performance, performance
• Features
• some free, some with additional work
• Open-source
• Modern web framework
• Dockerizable
• Future
• …
tweet #tarabica19
Guides and tools
• Migration docs
• https://docs.microsoft.com/en-us/aspnet/core/migration/proper-to-2x/?view=aspnetcore-2.2
• Should, When, and How Can I Migrate to .NET Core – Mitchel Sellers
• https://mitchelsellers.com/blogs/2018/07/19/should-when-and-how-can-i-migrate-to-net-core
• .NET Portability Analyzer
• https://docs.microsoft.com/en-us/dotnet/standard/analyzers/portability-analyzer
• https://github.com/Microsoft/dotnet-apiport
• Migrate project files tool
• https://github.com/hvanbakel/CsprojToVs2017
tweet #tarabica19
Thank you! Questions?
https://miroslavpopovic.com
@miroslavpopovic
Sponzori Generalni sponzor
Srebrni sponzori
Tehnički sponzori
tweet #tarabica19
Bronzani sponzor
Partner konferencije
1 of 36

Recommended

Migration from ASP.NET MVC to ASP.NET Core by
Migration from ASP.NET MVC to ASP.NET CoreMigration from ASP.NET MVC to ASP.NET Core
Migration from ASP.NET MVC to ASP.NET CoreMiroslav Popovic
356 views31 slides
Webアプリケーションフレームワークを利用した効率的なカスタムWeb開発 by
Webアプリケーションフレームワークを利用した効率的なカスタムWeb開発Webアプリケーションフレームワークを利用した効率的なカスタムWeb開発
Webアプリケーションフレームワークを利用した効率的なカスタムWeb開発Atsushi Matsuo
1.9K views46 slides
The future of ASP.NET / CodeCamp/Iasi 25 Oct 2014 by
The future of ASP.NET / CodeCamp/Iasi 25 Oct 2014The future of ASP.NET / CodeCamp/Iasi 25 Oct 2014
The future of ASP.NET / CodeCamp/Iasi 25 Oct 2014Enea Gabriel
1K views32 slides
Integrating Alfresco with Portals by
Integrating Alfresco with PortalsIntegrating Alfresco with Portals
Integrating Alfresco with PortalsPiergiorgio Lucidi
3.8K views63 slides
Webinar MVC6 by
Webinar MVC6Webinar MVC6
Webinar MVC6Suyati Technologies
881 views12 slides
Implementing portlets using Web Scripts by
Implementing portlets using Web ScriptsImplementing portlets using Web Scripts
Implementing portlets using Web ScriptsPiergiorgio Lucidi
704 views20 slides

More Related Content

What's hot

Practical Application of API-First in microservices development by
Practical Application of API-First in microservices developmentPractical Application of API-First in microservices development
Practical Application of API-First in microservices developmentChavdar Baikov
90 views19 slides
Yasgui: not just another sparql gui by
Yasgui: not just another sparql guiYasgui: not just another sparql gui
Yasgui: not just another sparql guilaurensrietveld
1.2K views22 slides
Process Orchestration with Flowable and Spring Boot by
Process Orchestration with Flowable and Spring BootProcess Orchestration with Flowable and Spring Boot
Process Orchestration with Flowable and Spring BootChavdar Baikov
747 views27 slides
Product Camp Silicon Valley 2018 - PM Technical Skills by
Product Camp Silicon Valley 2018 - PM Technical SkillsProduct Camp Silicon Valley 2018 - PM Technical Skills
Product Camp Silicon Valley 2018 - PM Technical SkillsSandeep Adwankar
241 views32 slides
ASP.NET Core: The best of the new bits by
ASP.NET Core: The best of the new bitsASP.NET Core: The best of the new bits
ASP.NET Core: The best of the new bitsKen Cenerelli
1.6K views50 slides
Alfresco WebScript Connector for Apache ManifoldCF by
Alfresco WebScript Connector for Apache ManifoldCFAlfresco WebScript Connector for Apache ManifoldCF
Alfresco WebScript Connector for Apache ManifoldCFPiergiorgio Lucidi
3.7K views30 slides

What's hot(20)

Practical Application of API-First in microservices development by Chavdar Baikov
Practical Application of API-First in microservices developmentPractical Application of API-First in microservices development
Practical Application of API-First in microservices development
Chavdar Baikov90 views
Yasgui: not just another sparql gui by laurensrietveld
Yasgui: not just another sparql guiYasgui: not just another sparql gui
Yasgui: not just another sparql gui
laurensrietveld1.2K views
Process Orchestration with Flowable and Spring Boot by Chavdar Baikov
Process Orchestration with Flowable and Spring BootProcess Orchestration with Flowable and Spring Boot
Process Orchestration with Flowable and Spring Boot
Chavdar Baikov747 views
Product Camp Silicon Valley 2018 - PM Technical Skills by Sandeep Adwankar
Product Camp Silicon Valley 2018 - PM Technical SkillsProduct Camp Silicon Valley 2018 - PM Technical Skills
Product Camp Silicon Valley 2018 - PM Technical Skills
Sandeep Adwankar241 views
ASP.NET Core: The best of the new bits by Ken Cenerelli
ASP.NET Core: The best of the new bitsASP.NET Core: The best of the new bits
ASP.NET Core: The best of the new bits
Ken Cenerelli1.6K views
Alfresco WebScript Connector for Apache ManifoldCF by Piergiorgio Lucidi
Alfresco WebScript Connector for Apache ManifoldCFAlfresco WebScript Connector for Apache ManifoldCF
Alfresco WebScript Connector for Apache ManifoldCF
Piergiorgio Lucidi3.7K views
Asp.Net 3 5 Part 1 by asim78
Asp.Net 3 5 Part 1Asp.Net 3 5 Part 1
Asp.Net 3 5 Part 1
asim782.4K views
Laravel and CodeIgniter: pros & cons by ElenorWisozk
Laravel and CodeIgniter: pros & consLaravel and CodeIgniter: pros & cons
Laravel and CodeIgniter: pros & cons
ElenorWisozk76 views
Merging two big Symfony based applications - SymfonyCon 2017 by Ivo Lukac
Merging two big Symfony based applications - SymfonyCon 2017Merging two big Symfony based applications - SymfonyCon 2017
Merging two big Symfony based applications - SymfonyCon 2017
Ivo Lukac1K views
The Need For Speed - NxtGen Cambridge by Phil Pursglove
The Need For Speed - NxtGen CambridgeThe Need For Speed - NxtGen Cambridge
The Need For Speed - NxtGen Cambridge
Phil Pursglove413 views
LF_APIStrat17_The Great API Redesign by LF_APIStrat
LF_APIStrat17_The Great API RedesignLF_APIStrat17_The Great API Redesign
LF_APIStrat17_The Great API Redesign
LF_APIStrat98 views
SPSNL16 - Building Office 365 and SharePoint solutions using modern developer... by Waldek Mastykarz
SPSNL16 - Building Office 365 and SharePoint solutions using modern developer...SPSNL16 - Building Office 365 and SharePoint solutions using modern developer...
SPSNL16 - Building Office 365 and SharePoint solutions using modern developer...
Waldek Mastykarz1.4K views
Mule soft meetup warsaw november 13th, 2019 by Patryk Bandurski
Mule soft meetup   warsaw november 13th, 2019Mule soft meetup   warsaw november 13th, 2019
Mule soft meetup warsaw november 13th, 2019
Patryk Bandurski416 views
Building Enterprise Apps with Sencha & DeftJS by ryancanulla
Building Enterprise Apps with Sencha & DeftJSBuilding Enterprise Apps with Sencha & DeftJS
Building Enterprise Apps with Sencha & DeftJS
ryancanulla1.3K views
Create Salesforce online IDE in 30 minutes by Jitendra Zaa
Create Salesforce online IDE in 30 minutesCreate Salesforce online IDE in 30 minutes
Create Salesforce online IDE in 30 minutes
Jitendra Zaa17.7K views
Projects In Laravel : Learn Laravel Building 10 Projects by Sam Dias
Projects In Laravel : Learn Laravel Building 10 ProjectsProjects In Laravel : Learn Laravel Building 10 Projects
Projects In Laravel : Learn Laravel Building 10 Projects
Sam Dias1.6K views
WordPress 4.4 and Beyond by Scott Taylor
WordPress 4.4 and BeyondWordPress 4.4 and Beyond
WordPress 4.4 and Beyond
Scott Taylor58.2K views

Similar to Tarabica 2019 - Migration from ASP.NET MVC to ASP.NET Core

Fast Track introduction to ASP.NET MVC by
Fast Track introduction to ASP.NET MVCFast Track introduction to ASP.NET MVC
Fast Track introduction to ASP.NET MVCAnkit Kashyap
937 views20 slides
Testing your Single Page Application by
Testing your Single Page ApplicationTesting your Single Page Application
Testing your Single Page ApplicationWekoslav Stefanovski
7.1K views17 slides
Net developer days presentation by
Net developer days   presentationNet developer days   presentation
Net developer days presentationAlexandre Malavasi
182 views39 slides
Develop a Quick and Dirty Web interface to your database: for the DBA and oth... by
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...Gabriel Villa
1.8K views18 slides
ASP.NET 5 Overview by
ASP.NET 5 OverviewASP.NET 5 Overview
ASP.NET 5 OverviewShahed Chowdhuri
7.5K views48 slides
Introduction to .NET Core & ASP.NET Core MVC by
Introduction to .NET Core & ASP.NET Core MVCIntroduction to .NET Core & ASP.NET Core MVC
Introduction to .NET Core & ASP.NET Core MVCSaineshwar bageri
654 views16 slides

Similar to Tarabica 2019 - Migration from ASP.NET MVC to ASP.NET Core(20)

Fast Track introduction to ASP.NET MVC by Ankit Kashyap
Fast Track introduction to ASP.NET MVCFast Track introduction to ASP.NET MVC
Fast Track introduction to ASP.NET MVC
Ankit Kashyap937 views
Develop a Quick and Dirty Web interface to your database: for the DBA and oth... by Gabriel Villa
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
Gabriel Villa1.8K views
Introduction to .NET Core & ASP.NET Core MVC by Saineshwar bageri
Introduction to .NET Core & ASP.NET Core MVCIntroduction to .NET Core & ASP.NET Core MVC
Introduction to .NET Core & ASP.NET Core MVC
Saineshwar bageri654 views
ASP.NET 5 Overview - Post Build 2015 by Shahed Chowdhuri
ASP.NET 5 Overview - Post Build 2015ASP.NET 5 Overview - Post Build 2015
ASP.NET 5 Overview - Post Build 2015
Shahed Chowdhuri2.4K views
Migrating .NET Application to .NET Core by Baris Ceviz
Migrating .NET Application to .NET CoreMigrating .NET Application to .NET Core
Migrating .NET Application to .NET Core
Baris Ceviz1.4K views
ASP.NET 5 Overview for Apex Systems by Shahed Chowdhuri
ASP.NET 5 Overview for Apex SystemsASP.NET 5 Overview for Apex Systems
ASP.NET 5 Overview for Apex Systems
Shahed Chowdhuri2.4K views
Introduction to ASP.NET 5 by mbaric
Introduction to ASP.NET 5Introduction to ASP.NET 5
Introduction to ASP.NET 5
mbaric2.4K views
How angularjs saves rails by Michael He
How angularjs saves railsHow angularjs saves rails
How angularjs saves rails
Michael He565 views
ASP.NET Core Demos Part 2 by Erik Noren
ASP.NET Core Demos Part 2ASP.NET Core Demos Part 2
ASP.NET Core Demos Part 2
Erik Noren400 views
Introducing ASP.NET vNext – The Future of .NET on the Server | FalafelCON 2014 by FalafelSoftware
Introducing ASP.NET vNext – The Future of .NET on the Server | FalafelCON 2014Introducing ASP.NET vNext – The Future of .NET on the Server | FalafelCON 2014
Introducing ASP.NET vNext – The Future of .NET on the Server | FalafelCON 2014
FalafelSoftware1.1K views
UPenn on Rails intro by Mat Schaffer
UPenn on Rails introUPenn on Rails intro
UPenn on Rails intro
Mat Schaffer823 views
Oleksandr Skachkov "Running С# in your Web Browser with WebAssembly" by Fwdays
Oleksandr Skachkov "Running С# in your Web Browser with WebAssembly"Oleksandr Skachkov "Running С# in your Web Browser with WebAssembly"
Oleksandr Skachkov "Running С# in your Web Browser with WebAssembly"
Fwdays351 views
Sitecore - what to look forward to by jinto77
Sitecore - what to look forward toSitecore - what to look forward to
Sitecore - what to look forward to
jinto77429 views

Recently uploaded

20231129 - Platform @ localhost 2023 - Application-driven infrastructure with... by
20231129 - Platform @ localhost 2023 - Application-driven infrastructure with...20231129 - Platform @ localhost 2023 - Application-driven infrastructure with...
20231129 - Platform @ localhost 2023 - Application-driven infrastructure with...sparkfabrik
8 views46 slides
FOSSLight Community Day 2023-11-30 by
FOSSLight Community Day 2023-11-30FOSSLight Community Day 2023-11-30
FOSSLight Community Day 2023-11-30Shane Coughlan
6 views18 slides
Page Object Model by
Page Object ModelPage Object Model
Page Object Modelartembondar5
6 views5 slides
The Era of Large Language Models.pptx by
The Era of Large Language Models.pptxThe Era of Large Language Models.pptx
The Era of Large Language Models.pptxAbdulVahedShaik
7 views9 slides
What is API by
What is APIWhat is API
What is APIartembondar5
10 views15 slides
SAP FOR CONTRACT MANUFACTURING.pdf by
SAP FOR CONTRACT MANUFACTURING.pdfSAP FOR CONTRACT MANUFACTURING.pdf
SAP FOR CONTRACT MANUFACTURING.pdfVirendra Rai, PMP
13 views2 slides

Recently uploaded(20)

20231129 - Platform @ localhost 2023 - Application-driven infrastructure with... by sparkfabrik
20231129 - Platform @ localhost 2023 - Application-driven infrastructure with...20231129 - Platform @ localhost 2023 - Application-driven infrastructure with...
20231129 - Platform @ localhost 2023 - Application-driven infrastructure with...
sparkfabrik8 views
FOSSLight Community Day 2023-11-30 by Shane Coughlan
FOSSLight Community Day 2023-11-30FOSSLight Community Day 2023-11-30
FOSSLight Community Day 2023-11-30
Shane Coughlan6 views
Gen Apps on Google Cloud PaLM2 and Codey APIs in Action by Márton Kodok
Gen Apps on Google Cloud PaLM2 and Codey APIs in ActionGen Apps on Google Cloud PaLM2 and Codey APIs in Action
Gen Apps on Google Cloud PaLM2 and Codey APIs in Action
Márton Kodok15 views
2023-November-Schneider Electric-Meetup-BCN Admin Group.pptx by animuscrm
2023-November-Schneider Electric-Meetup-BCN Admin Group.pptx2023-November-Schneider Electric-Meetup-BCN Admin Group.pptx
2023-November-Schneider Electric-Meetup-BCN Admin Group.pptx
animuscrm15 views
JioEngage_Presentation.pptx by admin125455
JioEngage_Presentation.pptxJioEngage_Presentation.pptx
JioEngage_Presentation.pptx
admin1254556 views
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P... by NimaTorabi2
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...
NimaTorabi215 views
Myths and Facts About Hospice Care: Busting Common Misconceptions by Care Coordinations
Myths and Facts About Hospice Care: Busting Common MisconceptionsMyths and Facts About Hospice Care: Busting Common Misconceptions
Myths and Facts About Hospice Care: Busting Common Misconceptions
BushraDBR: An Automatic Approach to Retrieving Duplicate Bug Reports by Ra'Fat Al-Msie'deen
BushraDBR: An Automatic Approach to Retrieving Duplicate Bug ReportsBushraDBR: An Automatic Approach to Retrieving Duplicate Bug Reports
BushraDBR: An Automatic Approach to Retrieving Duplicate Bug Reports
Software evolution understanding: Automatic extraction of software identifier... by Ra'Fat Al-Msie'deen
Software evolution understanding: Automatic extraction of software identifier...Software evolution understanding: Automatic extraction of software identifier...
Software evolution understanding: Automatic extraction of software identifier...
Introduction to Git Source Control by John Valentino
Introduction to Git Source ControlIntroduction to Git Source Control
Introduction to Git Source Control
John Valentino6 views
Copilot Prompting Toolkit_All Resources.pdf by Riccardo Zamana
Copilot Prompting Toolkit_All Resources.pdfCopilot Prompting Toolkit_All Resources.pdf
Copilot Prompting Toolkit_All Resources.pdf
Riccardo Zamana16 views
Dev-Cloud Conference 2023 - Continuous Deployment Showdown: Traditionelles CI... by Marc Müller
Dev-Cloud Conference 2023 - Continuous Deployment Showdown: Traditionelles CI...Dev-Cloud Conference 2023 - Continuous Deployment Showdown: Traditionelles CI...
Dev-Cloud Conference 2023 - Continuous Deployment Showdown: Traditionelles CI...
Marc Müller42 views
Team Transformation Tactics for Holistic Testing and Quality (Japan Symposium... by Lisi Hocke
Team Transformation Tactics for Holistic Testing and Quality (Japan Symposium...Team Transformation Tactics for Holistic Testing and Quality (Japan Symposium...
Team Transformation Tactics for Holistic Testing and Quality (Japan Symposium...
Lisi Hocke35 views
How Workforce Management Software Empowers SMEs | TraQSuite by TraQSuite
How Workforce Management Software Empowers SMEs | TraQSuiteHow Workforce Management Software Empowers SMEs | TraQSuite
How Workforce Management Software Empowers SMEs | TraQSuite
TraQSuite5 views

Tarabica 2019 - Migration from ASP.NET MVC to ASP.NET Core

Editor's Notes

  1. Image downloaded from: https://www.flickr.com/photos/markgregory/15693006019
  2. Image downloaded from: https://www.flickr.com/photos/andyhay/8196333166