Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-12037

Backup system ignores errors - we'd like it to report them


    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor Minor
    • 2.0
    • 2.0
    • Backup
    • None

      Currently the backup system tends to ignore errors return values. It calls lots of functions, which may return false, but does not always take action as a result of the return value.

      For 2.0 HEAD, we would like to change it as follows:

      1) When any function called during backup returns false, an error should be printed at that point. The error should make clear which activity or part of the data caused the error, so that [for example] the user could retry the backup without that activity.

      2) The system should continue with the backup as at present, but track whether an error occurred. At the end of a backup a clear message should display ('Backup completed succesfully' or 'Backup completed with errors').

      3) Depending on a config option, admins can set up the system so that when a backup has errors, it is aborted. (The abort would happen either at the point where the error occurs, or at the final stage, to be determined. But either way it wouldn't make the zip file.) This would be an option because sometimes there are backup problems that are not fatal and, for sites that don't have a development team, a partial backup is better than none.

      4) This config option should be configurable in the admin pages in the same place as any existing backup-related options.

      5) Moodle has a system for running scheduled backups. When a scheduled backup is running, this should always be continued (not aborted) even if errors occur, regardless of the config option.

        1. backup_log_patch.txt
          23 kB
          Dan Marsden
        2. backup_log_table.patch
          7 kB
          Dan Marsden
        3. backup_log_table.patch
          7 kB
          Dan Marsden
        4. error.patch
          24 kB
          Dan Marsden

            danmarsden Dan Marsden
            quen Sam Marshall
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            4 Vote for this issue
            6 Start watching this issue


                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.