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

Glossary database error after lots of recent activity

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.3
    • Fix Version/s: 2.3
    • Component/s: Glossary
    • Labels:
    • Testing Instructions:
      Hide

      There are several ways of doing this - the easy way, the other mostly easy way, or the insane way.

      Easy way:

      • Open /mod/glossary/lib.php
        • change the GLOSSARY_RECENT_ACTIVITY_LIMIT to something very low, like 1

      Mostly easy way:

      Hard way:

      • Create at least 50 glossary entries in 5 minutes

      General Procedure

      • Open a course
        • Ensure that the Recent activity block is shown
      • Create a new glossary
      • Create lots of entries (At least GLOSSARY_RECENT_ACTIVITY_LIMIT)
      • View the course page
        • Confirm no errors were shown
      Show
      There are several ways of doing this - the easy way, the other mostly easy way, or the insane way. Easy way: Open /mod/glossary/lib.php change the GLOSSARY_RECENT_ACTIVITY_LIMIT to something very low, like 1 Mostly easy way: Take an existing glossary with at least 50 entries and export them (or use http://moodle.org/pluginfile.php/855/mod_glossary/attachment/6031/texfilter_glossary_en.xml ) Import them into a new glossary Hard way: Create at least 50 glossary entries in 5 minutes General Procedure Open a course Ensure that the Recent activity block is shown Create a new glossary Create lots of entries (At least GLOSSARY_RECENT_ACTIVITY_LIMIT) View the course page Confirm no errors were shown
    • Affected Branches:
      MOODLE_23_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-33821-master-1

      Description

      Just been adding glossary support to the jmeter load testing scripts. In doing so, I'm obviously generating quite a few glossary entries in a short space of time. As a result, I've hit a bug in glossary_print_recent_activity() with an invalid SQL query.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

              Hide
              dobedobedoh Andrew Nicols added a comment -

              Caused by changes to the sql construction in MDL-30482.

              Show
              dobedobedoh Andrew Nicols added a comment - Caused by changes to the sql construction in MDL-30482 .
              Hide
              dobedobedoh Andrew Nicols added a comment -

              The bug is only demonstrated if the recent activity block is shown

              Show
              dobedobedoh Andrew Nicols added a comment - The bug is only demonstrated if the recent activity block is shown
              Hide
              dobedobedoh Andrew Nicols added a comment -

              Only affects Moodle 2.3

              Show
              dobedobedoh Andrew Nicols added a comment - Only affects Moodle 2.3
              Hide
              salvetore Michael de Raadt added a comment -

              Thanks for working on that, Andrew.

              Jason: I've added you here as a watcher. You might like to peer review this issue.

              Show
              salvetore Michael de Raadt added a comment - Thanks for working on that, Andrew. Jason: I've added you here as a watcher. You might like to peer review this issue.
              Hide
              phalacee Jason Fowler added a comment -

              Thanks for finding and fixing this Andrew, the fix looks good.

              Show
              phalacee Jason Fowler added a comment - Thanks for finding and fixing this Andrew, the fix looks good.
              Hide
              salvetore Michael de Raadt added a comment -

              Andrew: can you look at MDL-33707. I suspect it is a duplicate (or this is a duplicate, but anyway...). Is that the error you were seeing?

              Show
              salvetore Michael de Raadt added a comment - Andrew: can you look at MDL-33707 . I suspect it is a duplicate (or this is a duplicate, but anyway...). Is that the error you were seeing?
              Hide
              poltawski Dan Poltawski added a comment -

              Thanks Andrew, integrated this now.

              I've added the qa_test_required flag since I don't think we have any qa tests for recent activity block.

              Show
              poltawski Dan Poltawski added a comment - Thanks Andrew, integrated this now. I've added the qa_test_required flag since I don't think we have any qa tests for recent activity block.
              Hide
              dobedobedoh Andrew Nicols added a comment -

              Michael, MDL-33707 was indeed the same bug. I couldn't find it when I looked yesterday. Have closed it now as a duplicate.

              Show
              dobedobedoh Andrew Nicols added a comment - Michael, MDL-33707 was indeed the same bug. I couldn't find it when I looked yesterday. Have closed it now as a duplicate.
              Hide
              dobedobedoh Andrew Nicols added a comment -

              Added an alternative replication method - importing the entries from an existing glossary

              Show
              dobedobedoh Andrew Nicols added a comment - Added an alternative replication method - importing the entries from an existing glossary
              Hide
              ankit_frenz Ankit Agarwal added a comment -

              Hi,
              Tried the 'easy way' and 'mostly easy way'
              Everything is working great. No errors encountered.
              Thanks for fixing this

              Thanks

              Show
              ankit_frenz Ankit Agarwal added a comment - Hi, Tried the 'easy way' and 'mostly easy way' Everything is working great. No errors encountered. Thanks for fixing this Thanks
              Hide
              stronk7 Eloy Lafuente (stronk7) added a comment -

              And this has been incorporated to all the weekly builds and also, to Moodle 2.3 Release Candidate 1, yay!

              Many, many thanks for your hard work!

              Ciao

              Show
              stronk7 Eloy Lafuente (stronk7) added a comment - And this has been incorporated to all the weekly builds and also, to Moodle 2.3 Release Candidate 1, yay! Many, many thanks for your hard work! Ciao
              Hide
              tsala Helen Foster added a comment -

              I'm removing the qa_test_required label as we now have a QA test for the recent activity block: MDLQA-4601 Thanks for the suggestion Dan.

              If anyone thinks more QA tests are needed, please comment and re-add the qa_test_required label.

              Show
              tsala Helen Foster added a comment - I'm removing the qa_test_required label as we now have a QA test for the recent activity block: MDLQA-4601 Thanks for the suggestion Dan. If anyone thinks more QA tests are needed, please comment and re-add the qa_test_required label.

                People

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

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    25/Jun/12