-
Bug
-
Resolution: Deferred
-
Minor
-
None
-
3.4
-
None
-
MOODLE_34_STABLE
Firstly litle background to our moodle: We have over 3000 courses, many of them have backups files with size over 1.5GB. So daily backups takes some time to complete.
Because of this we started running to one problem: Times from table 'backup_courses' doesn´t match up to those in 'logstore_standard_log' for event course_backup_created. Time in logstore is greater then time of backup in table 'backup_courses'.
So when that happen this method backup_cron_helper::is_course_modified ( backup/util/helper/backup_cron_helper.class.php ) returns true. (Because it has found one change, that is '\core\event\course_backup_created') And because of that it will begin backup of course, instead of skipping it.
Solution is easy, replacing line 733 in backup/util/helper/backup_cron_helper.class.php
From:
$where = "courseid = :courseid and timecreated > :since and crud <> 'r'";
To:
$where = "courseid = :courseid and timecreated > :since and crud <> 'r' and eventname <> '\\core
event
course_backup_created'";
It is also probably also better practice to not count backup events as changes to the course in this context.
- will help resolve
-
MDL-72723 Change backup_cron_automated_helper::course_is_modified so it's not counting course modifications, just finding one.
-
- Closed
-