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

Improving performance when using scandir() during removal of excess backups

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Inactive
    • Affects Version/s: 2.3.2
    • Fix Version/s: None
    • Component/s: Backup
    • Labels:
    • Affected Branches:
      MOODLE_23_STABLE

      Description

      Currently we call the remove_excess_backups() method for each individual course. Each of them will call scandir() on the whole directory, we should think of a way to improve this.

      Possible solutions are:

      • Cache the directory content, but we have to be very careful not to use outdated information;
      • Update the method remove_excess_backups() so that it scans the directory only once and handle the excess backup for each courses found at once;

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                fred Frédéric Massart
                Participants:
                Component watchers:
                Adrian Greeve, Mihail Geshoski, Peter Dias
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: