25 Reasons to Move to Kentico Xperience MVC - Part 3
This is the third part of my 25 Reasons to Move to Kentico Xperience MVC blog post series. I am going to finish the list with the bigger picture technical reasons as to why MVC makes a ton of sense for Kentico Xperience over the legacy Portal Engine. Most of these should be somewhat clear and not take too much explanation.
If you haven't read the first two parts of the series, shame on you again, but feel free to go back over and read part one first and part two second, then jump back here.
Technical Benefits of a Modern Stack like ASP.NET Core MVC
The last category of Kentico Xperience MVC benefits is shaped around the technical conversation. This part of the argument is the most documented already with multiple other blog posts out there that talk about the technical benefits. For that reason, I am going to cover these the most quickly, however, in my opinion the technical reasons are the strongest case yet for the overall argument. Bottom line, when you add up the business, marketing, and technical reasons for rebuilding your site out of the legacy Portal Engine and into MVC, this list provides a pretty compelling and full business case. Let's get to it.
17. More Freedom
MVC gives developers the freedom to develop new features as they see fit, without Webforms getting in the way. If you need to add a Web API, or use EF Core, or add a Blazor project in connection with your Kentico Xperience content, this has never been easier because of the way you can organize your projects in the Kentico Xperience solution. By the way, that previous link is to fellow Kentico Xperience MVP Sean G Wright’s blog, you won't find many better resources outside of that blog for Kentico Xperience technical guidance.
Freedom also allows for new ideas and new technology solutions to be quickly executed and should lead to more innovative solutions as well. New NuGet packages can be used to try in your project very easily. MVC sites in Kentico Xperience are also easier to deploy and manage from a DevOps standpoint (more about DevOps later) as well because they are free from being dragged down by the legacy full ASP.NET Framework. Freedom is a good thing.
18. Granular Control
I’ve mentioned more control in the Marketing Benefits section of this list, but MVC enabling the full control over the rendered HTML is as much a technical benefit as it is a marketing benefit. It deserves a spot here too. For example, if you need to inject a single page application (SPA) into your MVC site it is almost a no brainer. Where in the Portal Engine this was somewhat a daunting task. Each element of the DOM is up to you and can be crafted however you like. This again was not true with the Portal Engine.
MVC also gives you the total control of routing and URL handing in your project (and the responsibility to handle it well). This point could be argued as a little bit of a double edged sword, because yes you have the control, but you also have to do the heavy lifting yourself. Portal engine developers argue that the Portal Engine gave them more out of the box than MVC, which is true. But I see it as the only 80% of what you actually want is in that box. The last 20% was always a battle to perfectly control and took quite a bit of time to make it "right" for modern best practices. I'd rather have more control and responsiblity than short cuts that may or may not work for my design or requirements fully.
19. Faster Website Performance
ASP.NET Core MVC flat out performs faster than ASP.NET Webforms. My favorite stat around the performance increase in Core is that the .Net Core C# compiler is roughly 2300% faster than the full framework. That’s an insane improvement. You can also easily do one Google search and find other stats about how many more requests the ASP.NET MVC Core pipeline can handle compared to the legacy full framework. As we mentioned back in the Marketing benefits section, this performance increase helps us to have better SEO through increase page speed performance, allows us to run our websites on less horsepower, and makes the editing experience less frustrating for content editors. It’s a win-win-win benefit. End users will also appreciate less flickering / page refreshes and less "white page spinning" time that older technology is burdened by. The pages just feel faster (when done right of course).
20. Separation of Concerns
This is one of my favorite benefits of moving to Kentico Xperience MVC. MVC provides clean separation of concerns (SoC) between the CMS Admin tool (which is still .Net full framework at time of writing) and the MVC Live Site (your live site which is just the presentation layer to the world).
This SoC allows you deploy the two sites independently, maintain them independently, scale them independently, and introduces more control and choice back to the development team. You no longer have to worry about breaking something in the production live site during a deployment of a custom module in your Xperience Admin tool. Conversely, if your site is having an issue , troubleshooting that issue in just your own MVC code is easier as opposed to reviewing the entire solution of Kentico Xperience. A stack trace will clearly tell you where issues are happening as opposed to hunting through 10 layers of Kentico database objects.
21. Enhanced Testability
Manual testing is the slowest, least reliable, and most expensive way to test an application, especially a CMS based application. But if applications aren’t designed to be testable, manual testing might be the only way available to us. That is really what we had in the Portal Engine because of the way it was designed. MVC provides a better and additional option for the developers to employ a natural Test Driven Development (TDD) methodology. ASP.NET Core MVC supports automated unit, integration, and functional testing. It's more inherent in the development methodology and more developers know how to do TDD with MVC than with WebForms. Enhanced testability is actually one of the core reasons that MVC has taken off in the Microsoft world in my opinion.
22. Rich User Experience
23. Stateless Apps
ASP.NET Core MVC in Kentico Xperience can follow the design of stateless nature of the web. From a developer's perspective, building a stateless MVC site can help make an application more maintainable and easier to work with. Developers don’t need to worry about things being correctly initialized in the session before loading a particular page. There are less “things” to remember. From an end user's perspective, statelessness allows pages to be more linkable and shareable. If a page is stateless, then links that are shared for a particular page work better, and we know that they'll see the correct thing, not just be redirected back to a home or listing page because they didn’t follow a specifc pattern to get there (Kentico Portal Engine e-commerce checkout I’m looking at you here!).
Stateless apps also scale and perform better, especially in a cloud like Azure or AWS.
24. Package Up
25. DevOps DevOps DevOps
I said it three times because it is that important. Think “Location, Location, Location”. Yes, it was technically possible to have full DevOps support with the Portal Engine, but it was not easy. That is because of having to automatically pick up and move (deploy) a full implementation of Kentico Portal based site has 10s of thousands of files and can take a long time to continuously integrate and deliver to multiple server environments. The ability to leverage DevOps processes (CI/CD) and platforms like Github and Azure DevOps (actions, pipelines, and releases) is flat out easier with MVC because of the separation of the MVC live site and CMS Administration tool. Heck with ASP.NET Core, Xperience 13 MVC containerization with Docker is now possible too.
Pro Tip: If you are having issues with your automating your deployments make sure you are using Kentico Xperience CI in your non production environments and think about using Compare for Kentico to compare those environments on the fly post deployment.
You don't just have to take my words for it. Here are a few more resources that give you more details of the differences between Kentico Portal Engine and Kentico Xperience MVC:
- Kentico Rocks episode 028, An interview with Brian McKeiver and Sean Wright on Kentico's future
- Kentico Xperience MVC Transition Guide
There you have it. It you made it through the whole list of 25 Reasons Why you Should Move to Kentico Xperience MVC I hope you found it beneficial. I’d love to know if you agree / disagree with me. Hit me up on Twitter @mcbeev or on email to share your opinion on the topic.
Simply stated though, I believe if you are not planning to get to MVC in your Kentico Xperience site already, you should be. Also, if you aren’t sure or need help, I might know a company that you could contact for help on Kentico Xperience Portal Engine to MVC migration.