Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-29857

getPrivateForumByOwnerAreaWithAllTopics results in a bad MySQL query plan

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: CLOSED
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.9.3, 10.5
    • Fix Version/s: 10.6
    • Component/s: Messages Tool
    • Labels:
    • 10 status:
      Resolved
    • 2.9 Status:
      Merge

      Description

      To replicate you really need a database with lots of forums, messages, etc. At least 500k rows in MFR_TOPIC_T

      getPrivateForumByOwnerAreaWithAllTopics is a method that is supposed to retrieve the private forums, topics, children all in one query. But this query results in two joins onto the same table. In MySQL 5.6+ I'm seeing this query ignore an index on the children table resulting in a full table scan (E.g., 4 seconds to load Messages instead of 0.05 seconds).

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                ottenhoff Sam Ottenhoff
                Reporter:
                ottenhoff Sam Ottenhoff
              • Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Git Source Code