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

Improve block_myoverview performance for the upgrading steps in Moodle 4.0

XMLWordPrintable

    • MOODLE_400_STABLE
    • MOODLE_400_STABLE
    • Hide

      Setup

      1. Edit blocks/myoverview/version.php and set $plugin->version to 2021052503
      2. Run "mdk run version", to reset block_myoverview version.
      3. Log in as admin
      4. Add the course overview block to the dashboard
      5. Log in as another user
      6. Add the course overview block to the dashboard
      7. Edit blocks/myoverview/version.php and set $plugin->version to 2021052504

      Testing instructions

      1. Login as admin and run the upgrade process
      2. Confirm you get an upgrade notice
      3. Start upgrade process
      4. Confirm you see a progress bar stating Deleting block instance
      5. Confirm you see a progress bar stating "Deleting user page block instance 2/2"
      6. Confirm the upgrade succeeds
      Show
      Setup Edit blocks/myoverview/version.php and set $plugin->version to 2021052503 Run "mdk run version", to reset block_myoverview version. Log in as admin Add the course overview block to the dashboard Log in as another user Add the course overview block to the dashboard Edit blocks/myoverview/version.php and set $plugin->version to 2021052504 Testing instructions Login as admin and run the upgrade process Confirm you get an upgrade notice Start upgrade process Confirm you see a progress bar stating Deleting block instance Confirm you see a progress bar stating "Deleting user page block instance 2/2" Confirm the upgrade succeeds
    • 1
    • Navigation push 14

      In MDL-70801 some changes were implemented in the myoverview block that requires some upgrading steps to be executed.

      While testing MDL-71696 in a big Moodle installation, I've seen this block is taking about 4 minutes to be upgraded:

      This instance had 54.758 users.

      A couple of things should be added to the upgrading process, to help admins during the upgrade process:

      • A progress bar should be added, to notify admins current status (otherwise, they might think the process has failed).
      • A recordset should be used in blocks/myoverview/db/upgrade.php (well spotted, Jun!!!)

        1. myoverview_upgrade.png
          14 kB
          Sara Arjona (@sarjona)
        2. Screenshot from 2022-02-28 15-45-45.png
          14 kB
          Ilya Tregubov
        3. Screenshot from 2022-02-28 16-48-50.png
          17 kB
          Ilya Tregubov
        4. Screenshot from 2022-02-28 16-52-36.png
          24 kB
          Ilya Tregubov
        5. Step 2_Screenshot1.PNG
          77 kB
          Gladys Basiana
        6. Step 2_Screenshot2.PNG
          58 kB
          Gladys Basiana
        7. Step 4_Screenshot.PNG
          30 kB
          Gladys Basiana
        8. Step 5_Screenshot.PNG
          29 kB
          Gladys Basiana
        9. Step 6_Screenshot.PNG
          57 kB
          Gladys Basiana

            mathewmay Glyn (Mathew) May
            sarjona Sara Arjona (@sarjona)
            Sara Arjona (@sarjona) Sara Arjona (@sarjona)
            Ilya Tregubov Ilya Tregubov
            Gladys Basiana Gladys Basiana
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

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

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