-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
4.2.8, 4.1.11
-
MOODLE_401_STABLE, MOODLE_402_STABLE
The enrol\lti\classes\local\ltiadvantage\task\sync_grades.php task, when there is a large number of grades to synchronize (in the order of tens of thousands), finishes execution but fails when writing of the log (apparently).
Furthermore, the stack trace is misleading because there is not a reading error but rather in the insert record as seen below.
In our specific case the last successful execution generated a 228MB log file!!!
In our opinion the log is too talking, the idea would be to put an "if(debugging())" before the "superfluous" mtraces in order to generate a lighter file.
We put this if before every mtrace that wasn't generated by an error.
I remain available.
... used 1630720 dbqueries
... used 3957.724408865 seconds
Scheduled task complete: Pubblicazione come tool LTI sincronizzazione valutazioni (enrol_lti\\local\\ltiadvantage\\task
sync_grades)
',
10 => 'ip-192-168-20-197.eu-west-1.compute.internal',
11 => 24047,
)]
Backtrace:
- line 293 of /lib/dml/moodle_read_slave_trait.php: call to moodle_database->query_end()
- line 1366 of /lib/dml/mysqli_native_moodle_database.php: call to mysqli_native_moodle_database->query_end()
- line 1412 of /lib/dml/mysqli_native_moodle_database.php: call to mysqli_native_moodle_database->insert_record_raw()
- line 86 of /lib/classes/task/database_logger.php: call to mysqli_native_moodle_database->insert_record()
- line 306 of /lib/classes/task/logmanager.php: call to core\task\database_logger::store_log_for_task()
- line 1152 of /lib/classes/task/manager.php: call to core\task\logmanager::finalise_log()
- line 272 of /lib/cronlib.php: call to core\task\manager::scheduled_task_complete()
- line 167 of /admin/cli/scheduled_task.php: call to cron_run_inner_scheduled_task()
!!! Error reading from database !!!
Debug info: MySQL server has gone away
SELECT * FROM mdl_task_scheduled WHERE classname = ?
[array (
0 => '\\enrol_lti\\local\\ltiadvantage\\task
sync_grades',
)]
Error code: dmlreadexception
Stack trace: * line 494 of /lib/dml/moodle_database.php: dml_read_exception thrown
- line 293 of /lib/dml/moodle_read_slave_trait.php: call to moodle_database->query_end()
- line 1282 of /lib/dml/mysqli_native_moodle_database.php: call to mysqli_native_moodle_database->query_end()
- line 1679 of /lib/dml/moodle_database.php: call to mysqli_native_moodle_database->get_records_sql()
- line 1651 of /lib/dml/moodle_database.php: call to moodle_database->get_record_sql()
- line 1630 of /lib/dml/moodle_database.php: call to moodle_database->get_record_select()
- line 1084 of /lib/classes/task/manager.php: call to moodle_database->get_record()
- line 291 of /lib/cronlib.php: call to core\task\manager::scheduled_task_failed()
- line 167 of /admin/cli/scheduled_task.php: call to cron_run_inner_scheduled_task()
- has a non-specific relationship to
-
MDL-77232 Optimize LTI 1.3 gradesync task
-
- Closed
-