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

Changing icon of preconfigured LTI tool is slow

    • MOODLE_400_STABLE, MOODLE_401_STABLE, MOODLE_402_STABLE, MOODLE_403_STABLE, MOODLE_404_STABLE, MOODLE_405_STABLE
    • MDL-81937_main
    • Hide
      1. Create a preconfigured external (LTI) tool
      2. Create two external tool (LTI) activities using the preconfigured tool
      3. Using a debugger (or just echo statements?) ensure that this line is only executed twice when changing the icon URL of the preconfigured tool
      Show
      Create a preconfigured external (LTI) tool Create two external tool (LTI) activities using the preconfigured tool Using a debugger (or just echo statements?) ensure that this line is only executed twice when changing the icon URL of the preconfigured tool

      When changing the icon of a preconfigured LTI tool the course module cache for all LTI activities based on that preconfigured tool gets purged. The SQL query that gets the affected course module IDs joins two tables at the wrong column causing the same course module IDs to be returned multiple times. This leads to unnecessary many calls to \course_modinfo::purge_course_module_cache() which has to acquire a lock, read from the cache, and release the lock each time it is called for the same course module.

      In our case this has lead to 1,287,389 calls to purge_course_module_cache() being made instead of "only" the 29,747 that are necessary.

            tschroeder Tim Schroeder
            tschroeder Tim Schroeder
            Mathew May Mathew May
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours
                2h

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