chamilo-lms
chamilo-lms copied to clipboard
Keep track of migration steps
Is your feature request related to a problem? Please describe. When upgrading from one version to another, Chamilo keeps a log of the steps it executes, but it doesn't keep a clear reference that the migration process could then use to "start again". We should be keeping a "step number" or something like that during any migration, so that a failure can then be recovered from without having to re-run the whole migration process again.
Describe the solution you'd like Store a "migration step" number for each line executed during the migration. This means adding such number inside the migration scripts or considering only one operation per migration method (currently identified by a timestamp). Also store some value if the migration was completed without error. This value should be stored in a file rather than the database. Something like chamilo/var/log/upgrade-version.log
Then make sure the migration script can find the previous number