Disclaimer: This website requires Please enable JavaScript in your browser settings for the best experience.

HomeDev GuideRecipesAPI Reference
Dev GuideAPI ReferenceUser GuideLegal TermsGitHubNuGetDev CommunityOptimizely AcademySubmit a ticketLog In
Dev Guide

Upgrade to CMS 9

Optimizely Content Management System (CMS 9) is a major version containing some incompatible API changes.

No data migration is required; updating to Optimizely Content Management System (CMS 9) is no different from updating to the feature updates delivered previously via NuGet. To make sure the upgrade is as smooth as possible, there are a few steps that you may want to take that are discussed in the next sections.

Breaking changes

A breaking change is a change that might cause other components to fail. When a breaking change is done to the signature of a method/class/interface, the old signature is often kept intact but set as obsolete and may cause a warning message in Visual Studio. As long as the Visual Studio project setting "Treat Warnings as Errors" is not enabled in Visual Studio, you can postpone fixing these warnings until later.

Classes that expose constructors that take dependencies are normally deleted without an obsolete warning in major releases because the compiler gives enough information about what to change. Keeping them makes dependency injection complex because there are multiple constructors to choose from that, over time, might or might not overlap.

In each major version, old obsolete methods are removed permanently to ensure that the API is kept clean and usable over time. So, even if you can postpone fixing warning messages, it is good practice to make sure all warning messages are fixed before upgrading to a major version. For CMS 9, many methods that were made obsolete in 8.0 are now deleted.

Note that EPiServer.CMS.Core no longer has a dependency on EPiServer.Logging.Log4Net. The NuGet package EPiServer.Logging.Log4Net may, because of this, be removed by NuGet when upgrading to CMS 9 (depending on the version of NuGet and in which order the packages were installed). After upgrading, you must manually ensure the package is installed to continue logging through Log4Net.

See Breaking changes in CMS 9

Upgrade add-ons

Add-ons managed with Visual Studio can be upgraded with the platform via NuGet. Add-ons that are installed via the user interface have to be upgraded through the user interface.

It is recommended that add-ons that are installed through the user interface are converted to NuGet add-ons after the upgrade to CMS 9. A tool can automatically convert add-ons previously managed via the user interface to be managed as NuGet packages via Visual Studio. For more instructions on converting user interface add-ons to NuGet add-ons, see Linus Ekström's blog post Upgrade your site and add-ons to EPiServer CMS 8 pre-release.

Incompatible add-ons installed via the user interface must be disabled to reach the user interface and the update functionality. An exception message is shown with information on how to disable an add-on that blocks startup. You can read more about disabling add-ons and UI versus Visual Studio add-ons.