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

refresh_mod_calendar_events_task does not release lock when running cron in parallel

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Minor Minor
    • None
    • 3.3.2
    • Administration, Tasks
    • None
    • MOODLE_33_STABLE

      Reference from post: https://moodle.org/mod/forum/discuss.php?d=365485

       

      Hello, I recently tried to run the cron of a Moodle instance from multiple nodes and I got the error below on one of the nodes:

      // Execute adhoc task: core\task\refresh_mod_calendar_events_task
      ... started 11:20:47. Current memory use 20MB.
      Refreshing events for assign
      !!! Coding error detected, it must be fixed by a programmer: A lock was created but not released at:
      [dirroot]/lib/classes/task/manager.php on line 448
       
      Code should look like:
       
      $factory = \core\lock\lock_config::get_lock_factory('type');
      $lock = $factory->get_lock(Resource id #728);
      $lock->release(); // Locks must ALWAYS be released like this.
       
      !!!
      

      I posted a message to the forums (see above) but I though is a good idea to report it here as well.

      As I explained in the forums I couldnt find the task 

      core\task\refresh_mod_calendar_events_task

       
      Does anyone else noticed this issue? Is there a way to know why the lock is not released?

       

      The only plugin related to assignments I have installed is Turnitin plagiarism plugin.

            Unassigned Unassigned
            christos312 christos
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

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