Details

      Description

      The method forum_get_subscribed_forums() found in mod/forum/lib.php doesn't make use of the passed course, so it gets information on all forums on the site instead of just ones for the course. This has proven to be a very large performance hit on sites with a lot of forums.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

              Hide
              bushido Mark Nielsen added a comment -

              Attaching patches for Moodle 1.9 (Moodle1.patch) and Moodle 2.1 (Moodle2.patch)

              Show
              bushido Mark Nielsen added a comment - Attaching patches for Moodle 1.9 (Moodle1.patch) and Moodle 2.1 (Moodle2.patch)
              Hide
              bushido Mark Nielsen added a comment -

              Also note that forum_get_subscribed_forums() is only used on index.php, so regression testing should be minimal.

              Show
              bushido Mark Nielsen added a comment - Also note that forum_get_subscribed_forums() is only used on index.php, so regression testing should be minimal.
              Hide
              salvetore Michael de Raadt added a comment -

              Thanks for spotting that and supplying a solution.

              Show
              salvetore Michael de Raadt added a comment - Thanks for spotting that and supplying a solution.
              Hide
              skodak Petr Skoda added a comment -

              to integrators: please cherry pick to supported 2.x branches too

              Thanks for the report and patch!

              Show
              skodak Petr Skoda added a comment - to integrators: please cherry pick to supported 2.x branches too Thanks for the report and patch!
              Hide
              stronk7 Eloy Lafuente (stronk7) added a comment -

              Integrated (21, 22 & master), thanks!

              Show
              stronk7 Eloy Lafuente (stronk7) added a comment - Integrated (21, 22 & master), thanks!
              Hide
              stronk7 Eloy Lafuente (stronk7) added a comment -

              Passing this. I've tested it as admin/teacher/pupil against forced, prevented and normal subscription forums. All buttons and statuses seem to have sense.

              PS: I've noticed 2 minor (unrelated) problems while testing, will be searching/creating them later.

              Show
              stronk7 Eloy Lafuente (stronk7) added a comment - Passing this. I've tested it as admin/teacher/pupil against forced, prevented and normal subscription forums. All buttons and statuses seem to have sense. PS: I've noticed 2 minor (unrelated) problems while testing, will be searching/creating them later.
              Hide
              stronk7 Eloy Lafuente (stronk7) added a comment -

              Your nice code represents only 1/46 of the issues that have been sent upstream this week, so thanks, but not many.

              Nah, joking, many thanks! Closing this a fixed, ciao

              Show
              stronk7 Eloy Lafuente (stronk7) added a comment - Your nice code represents only 1/46 of the issues that have been sent upstream this week, so thanks, but not many. Nah, joking, many thanks! Closing this a fixed, ciao

                People

                • Votes:
                  2 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    12/Mar/12