Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Entry JSON data update for when their controller has changed #3

Open
sveetch opened this issue Apr 15, 2024 · 0 comments
Open

Entry JSON data update for when their controller has changed #3

sveetch opened this issue Apr 15, 2024 · 0 comments
Labels
idea Idea about feature or new concept

Comments

@sveetch
Copy link
Member

sveetch commented Apr 15, 2024

Since a Controller can change to add new fields, remove fields or edit field options, the saved JSON data in previous version won't fit anymore to the new Controller structure and options.

At first, the usage of entry JSON data must always be compatible with new Controller version such as it won't break the data listing.

Then we would need a safe way to upgrade data from previous controller version. For this we have added a "version" value on entry that is filled with current controller version, so we can more easily know what entries are up to date or not.

To start with this, we need to predict and choose how we manage these differences. Then we would be able to code the upgrade features. It should be at least available from a commandline since it is flawless for heavy migration when Controller have a lot of data. And maybe we could think of an Admin action, but it could be risky with huge process and request timeout.

  • When a new field is added, the data must include it with a blank value (this would need a default value on definition);
  • When an existing field is removed, the data must be cleaned to remove it;
@sveetch sveetch added the idea Idea about feature or new concept label Apr 15, 2024
@sveetch sveetch changed the title Update entry JSON data for when their controller has changed Entry JSON data update for when their controller has changed Apr 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
idea Idea about feature or new concept
Projects
None yet
Development

No branches or pull requests

1 participant