COU-341 - Data loss when deploying changes to Member Types

Created by Rune Strand 06 Jun 2016, 13:10:50 Updated by Sebastiaan Janssen 08 Jun 2016, 14:25:29

The problem

This affects versions of Umbraco 7.3.0 -> 7.4.3 when running Courier deployments for Member Type changes. Specifically, the data loss issue occurs when:

  • 2 environments have the same Member Type
  • the #1 environment renames a Member Type Property Type alias
  • this change is pushed to the #2 environment
  • If the #2 environment has members with custom data, the custom data will be lost. Username/password and login information are retained

The members themselves will not disappear but all custom properties are wiped.

The cause

This issue is due to an Umbraco Core bug between 7.3.0 -> 7.4.3. Whenever a Member Type is saved in the core, new GUID/Unique IDs are generated for all Member Type Property Types and Property Groups. Since Courier relies on GUIDs being consistent between environments, Courier will assume that all of the Property Types and Property Groups have been removed and new ones have been added. The data loss occurs because when a Property Type is deleted, so is all affiliated property data.

The fix

The Umbraco Core fix is detailed here: http://issues.umbraco.org/issue/U4-8569 This fix will be rolled out with a the new 7.4.4 version in the coming couple of weeks.

A new version of Courier (2.52.7) will be released asap to mitigate this issue. This Courier release will:

  • Revert to the behavior of Courier prior to Umbraco's 7.3.0 release for how it treated Property Type and Property Group alias changes for Member Types: ** This means that renaming of a Member Type's Property Type or Property Group will not work, instead a new Property Type/Group will be created on the destination ** This prevents the data loss issue ** Property Type/Groups would then need to be manually managed at the destination

This will only affect Member Types, this will not affect Content/Media Types and renaming of Property Types/Groups for Content/Media types will continue to work as expected.

Comments

Shannon Deminick 08 Jun 2016, 10:45:03

Have reviewed the code changes and have tested this by:

  • Creating a new UaaS site
  • Adding a custom group and property types to the Member Member Type on the UaaS site
  • Creating a few members of this type with filled in property data
  • Cloning the site to my local machine
  • Running the site locally and restoring any content
  • Creating a few members of 'Member' Member Type locally
  • Renaming the property group and property type aliases
  • Checking that everything works locally, no data loss, everything is renamed correctly
  • Push courier file changes in Git to UaaS site
  • Navigate to one of the members originally created - There is no data loss, the property data and property groups remain as-is, however there is now a new property group and new property types which is the expected behavior since renames for Member Type Property Types/Groups will not be supported until Umbraco Core 7.4.4 is released to fix the underlying issue
  • To re-check again, I renamed my local Property Types/Groups back to what they originally were
  • Push to UaaS
  • Navigate to one of the members originally created - There is no data loss, the property data and property groups remain as-is, however the additional group and property types previously created still remain which is the expected behavior since renames for Member Type Property Types/Groups will not be supported until Umbraco Core 7.4.4 is released to fix the underlying issue


Priority: Major

Type: Bug

State: Fixed

Assignee:

Difficulty:

Category:

Backwards Compatible: True

Fix Submitted:

Affected versions:

Due in version: 2.52.7

Sprint: Sprint 35

Story Points:

Cycle: