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

When duplicating module the course cache is rebuilt twice

    XMLWordPrintable

Details

    • MOODLE_33_STABLE
    • MOODLE_32_STABLE, MOODLE_33_STABLE
    • wip-MDL-59311-master
    • Hide
      1. Duplicate last module in a section
      2. Refresh course page and make sure the duplicated module is still in the correct position
      3. Duplicate another module (not the last one)
      4. Refresh course page and make sure the duplicated module is right below the original module

      If you want to test performance win:

      1. Create a course with many modules
      2. Open course page in editing mode
      3. Add 'logall' => 1 to the $CFG->dboptions in the config.php
      4. Duplicate a module
      5. Count the number of new records in mdl_log_queries table
      6. Revert the commit
      7. Duplicate a module
      8. Count the number of new records in mdl_log_queries table - it is much larger (the bigger the course the larger is the difference)
      9. Remove 'logall'
      Show
      Duplicate last module in a section Refresh course page and make sure the duplicated module is still in the correct position Duplicate another module (not the last one) Refresh course page and make sure the duplicated module is right below the original module If you want to test performance win: Create a course with many modules Open course page in editing mode Add 'logall' => 1 to the $CFG->dboptions in the config.php Duplicate a module Count the number of new records in mdl_log_queries table Revert the commit Duplicate a module Count the number of new records in mdl_log_queries table - it is much larger (the bigger the course the larger is the difference) Remove 'logall'

    Description

      Noticed while looking at MDL-59300 - that's a performance problem. Rebuilding course cache on large courses can take long time.

      Attachments

        Issue Links

          Activity

            People

              marina Marina Glancy
              marina Marina Glancy
              Mark Nelson Mark Nelson
              David Monllaó David Monllaó
              Simey Lameze Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                11/Sep/17