Belitsoft > Senior .NET Developer Interview Questions and Answers

ASP.NET to ASP.NET Core Migration in the USA

Contents

Migration is hard: ASP.NET-based systems depend on outdated libraries, and ASP.NET Core works in a different way

ASP.NET Framework applications are hard to update because they rely on System.Web, HttpContext, outdated packages, old build tools, and deprecated APIs. 

Features like session-state and authentication work differently in ASP.NET Core, meaning they cannot just be copied over and must be rewritten.

Supporting libraries often depend on several other packages, requiring you to upgrade them in a specific order. Additionally, the entire hosting model has changed. A middleware pipeline has replaced the older modules and handlers, changing how the application processes requests. 

Because the code is usually deeply interconnected, upgrading these older .NET applications is difficult, typically taking experienced ASP.NET Core engineering teams several months to finish.

Incremental migration: move ASP.NET-based system in small parts while it keeps working

Microsoft recommends incremental migration using the Strangler-Fig pattern for large applications with well-known dependencies or those that depend on System.Web. This approach keeps the code of old and new systems working side by side, so the core business application stays online.

Full, total or complete rewrites at once are only recommended for small applications with minimal dependencies. 

Engineering teams at modernization vendors, such as Belitsoft, use the Strangler-Fig pattern to migrate applications piece by piece, replacing legacy modules one by one without downtime.

Question

We have a healthcare platform built on old ASP.NET MVC. As we get more users, the site is slowing down, and our server bills are too high. We need to move to the latest .NET so we can use Linux and cut costs.

Database. All our data code uses NHibernate. We want to use the new ASP.NET Core Identity for logins, but it is built to work with Entity Framework Core. Should we rewrite our entire database just to fit EF Core?

User Passwords. We have thousands of doctors and providers using the site. The old system and the new one use different ways to encrypt passwords. We cannot ask everyone to reset their passwords.

Plugins. We rely on MvcSiteMapProvider and legacy DevExpress for reports. Neither works with modern .NET. Is there a way to make these work, or do we have to build the menus from scratch and purchase an upgrade to the latest DevExpress?

We want to cut our server costs by switching to Linux. Should we try to move the current code over as-is, or is it better to just rewrite these specific parts from scratch?

Answer

Database. Do not rewrite your database to fit EF Core. Keep your NHibernate logic for complex data, but use Dapper to connect ASP.NET Core Identity. Dapper is a "micro-ORM" that does not depend on EF Core rules. It will work with your existing tables without a schema rewrite, and it is faster than what you are using now.

User Passwords. When a doctor logs in, the system checks the old hash. If it matches, the system immediately re-hashes it using modern security standards and saves it to the new database. The user never notices anything.

Plugins. MvcSiteMapProvider does not work on modern .NET. Build a custom navigation view component that will not break in the next update. For DevExpress, manually upgrade the report files to the latest release. This is some manual work, but much cheaper than a total rewrite.

Moving to Linux and containers will cut costs. Given your setup, rewriting only the Identity and navigation modules is the right approach. The rest can be ported directly to the new .NET LTS framework.

Never miss a post! Share it!

Written by
Chief Innovation Officer / Partner
I've been leading a department specializing in custom software development for 20 years.
5.0
1 review

Rate this article

Leave a comment
Your email address will not be published.

Recommended posts

Belitsoft Blog for Entrepreneurs

Our Clients' Feedback

zensai
technicolor
crismon
berkeley
hathway
howcast
fraunhofer
apollomatrix
key2know
regenmed
moblers
showcast
ticken
Next slide
Let's Talk Business
Do you have a software development project to implement? We have people to work on it. We will be glad to answer all your questions as well as estimate any project of yours. Use the form below to describe the project and we will get in touch with you within 1 business day.
Contact form
We will process your personal data as described in the privacy notice
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply
Contact us

USA +1 (917) 410-57-57
700 N Fairfax St Ste 614, Alexandria, VA, 22314 - 2040, United States

UK +44 (20) 3318-18-53
26/28 Hammersmith Grove, London W6 7HA

Poland +48 222 922 436
Warsaw, Poland, st. Elektoralna 13/103

Email us

[email protected]

to top