Breaking changes in CMS 10
This topic describes breaking changes for Optimizely Content Management System (CMS 10) in relation to previous version 9, and the steps needed to update affected code.
To view the complete list of changes, see the release notes feed.
Some changes are binary breaking but do not necessarily require code changes but rather a project recompilation. Breaking changes are changes in method signatures or behavior of methods compared to the documented API in the previous version, which is described in this document.
The new ".Internal" namespaces
One of the bigger changes is that all APIs were reviewed to find internal implementation classes and that those were moved to internal namespaces. You can see exactly which APIs are affected in these stories: CMS-3762 (Episerver CMS Core) and CMS-3755 (Episerver CMS UI). Read more about these changes in Henrik Nyström's blog post.
Event system
The event system (used primarily for communication between instances in a load-balanced environment) will no longer guarantee that events are processed sequentially, one at a time. Code that uses the event system should be reviewed for thread safety and cannot rely on the order in which events arrive to the event listener.
Implementors of custom event providers should also be aware that SendMessage calls are no longer guaranteed to run in a separate thread and should, therefore, take precautions to ensure optimal performance.
Remove support for legacy dot notation for dojo modules
Optimizely is removing the support for the legacy dot notation for dojo modules, for example, epi-cms.editing.ContentPicker. This means that you need to change all EditorDescriptors, Components and so on where you have defined your Dojo modules using the . to /. Read more CMS-2295 and in Ben McKernan's blog post.
EPiServer.Shell moved to EPiServer.CMS.UI.Core
EPiServer.Shell.dll was moved from NuGet package EPiServer.Framework to EPiServer.CMS.UI.Core. If you have both packages installed, no change is required. Read more in CMS-1380.
NoteIf you get an error message saying Value cannot be null.Parameter name: virtualPath]in EPiServer.Shell.ShellInitialization.WaitForInitializeModules()..., remove the
EPiServer.Shell.dllfrom the site bin folder. This may happen for sites that do not have theEPiServer.CMS.UI.Coreinstalled, for example Commerce Manager.
Converting the database to UTC is a required step
Running the database with local date and time will no longer be supported (CMS-1449). A database not converted to UTC will throw an exception to avoid data loss caused by mixing local and UTC date and time. Conversion can be done before upgrading for versions 9.1 or later, for example, using the provided PowerShell scripts, see Storing UTC date and time in the database for more details. A setting can be added to the appSettings section of web.config to disable the exception if the site temporarily have to be started without doing the conversion, add episerver:DisableDateTimeKindValidation with value true.
More breaking changes in UI:
- CMS-4925 Objects of type
epi._Dependencycan no longer be created - CMS-1202
GetContentByPermanentLinkQuerywill always return the content without work id - CMS-2710 Dialog now has
destroyOnHide:trueby default - CMS-4319 The value of
enum ExtendedVersionStatus.Expiredhave changed - CMS-1150 Calling
watchModelChangeand unwatchModelChangeon_Command.jshas been deprecated
More breaking changes in Core:
- CMS-4110 The event args in the post event
MovedContentwill now contain the content loaded after the move - CMS-3852
ContentStoremethods for saving data has been removed - CMS-3756
IAvailableModelSettingsRepositorymethod signature changes - CMS-3763
ContentScannerExtensionmethod signature changes - CMS-3166
ContentSearchHandlerchanged to an abstract class - CMS-3131
LocalizationServicenow returns fallback language before fallback defined in code - CMS-1197
LanguageBranchnow implementsIReadOnlyandLanguageBranch.URLSegmentwill now return theLanguageIDif not set to a custom value - CMS-1320 Browsing to expired page will now return a 404
- CMS-1266 No longer allowed to have the wildcard host as the only host for any given language
- CMS-2078 Align status transitions, events and required access rights when saving
- CMS-3824
UrlSegmenthave been replaced withIUrlSegmentCreator/IUrlSegmentLocator/IUrlSegmentGenerator - CMS-3823
SiteDefinitionRepositoryandSiteDefinitionResolverhave been replaced withISiteDefinitionRepositoryandISiteDefinitionResolver - CMS-3090 Added validation of virtual content type properties defined on interfaces
- CMS-3153
IContentVersionRepositorylist methods have been consolidated into one.PageVersionis obsoleted. - CMS-3449
PropertyResolverchanged to an abstract class - CMS-3530 New method
ImportPropertiesintroduced onIContentTransfer - CMS-3591
HostDefinitionExtensions.FirstOfTypereturn wildcard host last - CMS-3764
AdministrationSettingsServiceis replaced withIAdministrationSettingsService - CMS-3854 Extended
IContentEventswith eventsRequestingApprovalandRequestedApproval - CMS-3859 Create a language branch of a non-localized content should not be possible
- CMS-3860
GetDefaultwhen content implementsILocalebut nowILocalizablewill not set language - CMS-1206
IContentVersionRepository.Deletemethod will now throw an exception when a version cannot be deleted - CMS-3982 New event
ContentSecuritySavingadded toIContentSecurityRepository - CMS-3983 Event args type changed on
ContentLanguageSettingRepository - CMS-3987
PropertyDate.Date/PageData.StartPublish/PageData.StopPublishare now nullable - CMS-4167
ContentCoreData.StartPublish/StopPublishproperties are now nullable - CMS-3812 Empty properties were changed to work more like standard .NET properties
- CMS-3991 Methods removed from
IPermanentLinkMapper - CMS-4149 Experimental setting
UseLegacyValueTypefrom EPiServer 7 to return legacy value types has been removed - CMS-2807
ContentLanguageSettingswere replaced withIContentLanguageSettingsandContentLanguageSettingsResolver - CMS-4445 Delay publish job is now impersonating the user that scheduled the publish
- CMS-4537
IScheduledJobStatusService.ReportExecutedJobmethod signature changed - CMS-4219
PropertyLinkCollectionno longer inheritsPropertyXhtmlString. It is now a direct base class toPropertyLongString.
Updated 3 days ago