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

Improve H5P contentype is_view_allowed function

    XMLWordPrintable

Details

    • MOODLE_311_STABLE
    • Moppies Kanban, Old Moppies Kanban Board

    Description

      on a site, with the H5P contentbank, it takes forever to load the page. 

      DEBUGINFO:

      the site is "normally" filled (not a massive course, but not small either), but relies heavily on H5P. 

      Whenever I click on the "contentbank" of this course, it takes about 4 / 4.5 minutes to load the page. In the DevTools of chrome, is says it takes about 4.5 minutes for TTFB (time to first byte)

      {}INSERT IMAGE HERE{}

       

      after that the content bank is loaded quite normally

      {}INSTERT IMAGE HERE{}

       

      As you see, there are quite some H5P items created in this course, though for this customer / course it even ain't "that much"..

      What happens upon loading the content bank?

      HYPOTHESES:

        • for every item in the contentbank Moodle tries to get the libraries from H5P, and it gets loaded from an external source*

       

      ---------- 

      After some researching the problems seems to be on is_view_allowed function implementation for H5P contenttype. The function is getting the library from the content to check whether the user can view the content or not. This issue is about looking for a better way to get that information or maybe store some more information about the H5P content in the database to make it quicker to check.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ddubbeldam Daniel Dubbeldam
              Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Laurent David, Raquel Ortega, Sara Arjona (@sarjona), Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Laurent David, Raquel Ortega, Sara Arjona (@sarjona)
              Votes:
              2 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 week
                  1w