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

Make databasemeta cache a simpledata cache and improve performance

    XMLWordPrintable

Details

    • MOODLE_30_STABLE
    • MOODLE_31_STABLE
    • Hide

      Database meta calls are used throughout the entire system.

      1. All PHPUnit and Behat tests must pass on ALL databases.
      2. Installing a new site and browsing around works.
      3. Restoring the course from MDL-40579 works without error (There may be warnings that aren't related to database meta)

      For performance verification;
      1. Obtain the script from MDL-53208 and run that on official master (before integration)
      2. Run the script again with the integrated version. Compare results.

      As it's now using simple data the performance will be much greater. Be warned that integration of MDL-53208 will also increase performance so my may be measuring the changes from both in this test. MDL-53208 improves across the board, where this is specific to the database meta cache.

      Show
      Database meta calls are used throughout the entire system. 1. All PHPUnit and Behat tests must pass on ALL databases. 2. Installing a new site and browsing around works. 3. Restoring the course from MDL-40579 works without error (There may be warnings that aren't related to database meta) For performance verification; 1. Obtain the script from MDL-53208 and run that on official master (before integration) 2. Run the script again with the integrated version. Compare results. As it's now using simple data the performance will be much greater. Be warned that integration of MDL-53208 will also increase performance so my may be measuring the changes from both in this test. MDL-53208 improves across the board, where this is specific to the database meta cache.

    Description

      1. Update the database_column_info class so that it can only be read from once constructed. This means references passed around are not a problem.
      2. update the cache information to state databasemeta now uses 'simpledata'.
      3. update the sql generator so that it uses isset for tables rather than an array search.
      4. Cache the cache instance inside the database class as calling cache::make() is expensive.

      Attachments

        Issue Links

          Activity

            People

              mr-russ Russell Smith
              mr-russ Russell Smith
              Marina Glancy Marina Glancy
              Dan Poltawski Dan Poltawski
              Rajesh Taneja Rajesh Taneja
              Matteo Scaramuccia, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo, Matteo Scaramuccia, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              2 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                23/May/16