The problem: there is no way to migrate the data contained in the RMS to a new version of the application except if the application don't have any change on the Persistable classes structure, otherwise the RMS data will be read incorrectly leading to inconsistent data or exceptions.
The proposed solution: a class that will help on the migration process. Below I create a scratch of how it can work:
//the Person class had added a new field called specialFood between versions
Person person = new Person();
//it will start the update process and return a list of all Person deserialized into a Map
List<Map> entities = UpdateManager.start(Person.class);
Map entity = entities.get(..);
//here we set the ID of the object being uptaed
//the new field will be set now
//replacing the old person if a new structure data
//it will finish the process and update the new structure of the Person RMS
Log in to post a comment.