Skip to content
This repository has been archived by the owner on Sep 6, 2023. It is now read-only.

Upgrade to obsoleted fields #78

Merged
merged 12 commits into from
Jan 6, 2023
Merged

Upgrade to obsoleted fields #78

merged 12 commits into from
Jan 6, 2023

Conversation

DuttaSoumya
Copy link
Contributor

@DuttaSoumya DuttaSoumya commented Jan 3, 2023

Upgrading to new versions may lead the export configuration to enter an incorrect state, say, if a field that was being exported has now been obsoleted.

The following change makes the solution more robust by,

  • Issuing an error upon upgrade when such a condition is met, so user gets a chance to fix the errors.
  • If an upgrade is forced by the system (after enough attempts to upgrade have failed), the extension gets uninstalled. Re-installing the extension (with the bad underlying data) should force disabling of tables with such invalid fields
  • A notification issued when user opens the main export page lets user be aware that some of the fields currently enabled for export are invalid.
  • Enabling the export of a table now checks for any invalid fields that are configured to be exported.

SITUATION
Table T with fields F1 and F2 are part of the export schema and are being exported to the lake. Current BC version is V1, say.
In version V1, both F1 and F2 are active fields.
In the next version V2, field F2 has ObsoleteState = Removed.

TRIGGER
Upgrade of system from version V1 to V2 starts.

image

@DuttaSoumya DuttaSoumya merged commit 043fbf7 into main Jan 6, 2023
@DuttaSoumya DuttaSoumya deleted the UpgradeToObsoletedFields branch January 6, 2023 15:01
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant