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

Event monitor is storing events in DB when no rules defined.

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Blocker
    • 2.8
    • 2.8
    • Logging
    • MOODLE_28_STABLE
    • MOODLE_28_STABLE
    • MDL-47900_master
    • Hide
      Test 1
      1. Delete any event monitor rules on the site you may have.
      2. Run the cron and check that the 'tool_monitor_events' table is empty.
      3. Visit a course and add an assignment/book/whatever.
      4. Confirm that the 'tool_monitor_events' table is still empty.
      5. Add some rules for a set of events (remember them).
      6. Perform the particular events associated with the rules you created.
      7. Confirm that the 'tool_monitor_events' table is still empty.
      8. Subscribe to these rules in a particular course.
      9. Perform the particular events associated with the rules you created in a different course than the one you subscribed to rules in.
      10. Confirm that the 'tool_monitor_events' table is still empty.
      11. Perform the particular events associated with the rules you created in the same course you subscribed to rules in.
      12. Check that these events are now stored in the 'tool_monitor_events' table.
      Test 2
      1. Run all the unit tests in admin/tool/monitor/tests.
      Show
      Test 1 Delete any event monitor rules on the site you may have. Run the cron and check that the 'tool_monitor_events' table is empty. Visit a course and add an assignment/book/whatever. Confirm that the 'tool_monitor_events' table is still empty. Add some rules for a set of events (remember them). Perform the particular events associated with the rules you created. Confirm that the 'tool_monitor_events' table is still empty. Subscribe to these rules in a particular course. Perform the particular events associated with the rules you created in a different course than the one you subscribed to rules in. Confirm that the 'tool_monitor_events' table is still empty. Perform the particular events associated with the rules you created in the same course you subscribed to rules in. Check that these events are now stored in the 'tool_monitor_events' table. Test 2 Run all the unit tests in admin/tool/monitor/tests.

    Description

      mysql> select count(id) from tool_monitor_rules;
      +-----------+
      | count(id) |
      +-----------+
      |         0 |
      +-----------+
      1 row in set (0.18 sec)
       
      mysql> select count(id) from tool_monitor_subscriptions;
      +-----------+
      | count(id) |
      +-----------+
      |         0 |
      +-----------+
      1 row in set (0.00 sec)
       
      mysql> select count(id) from tool_monitor_events;
      +-----------+
      | count(id) |
      +-----------+
      |      3797 |
      +-----------+
      1 row in set (0.00 sec)
       
      mysql> select * from tool_monitor_events limit 3;
      +--------+------------------------------------+-----------+--------------+-------------------+---------------------------------------------------+----------+-------------+
      | id     | eventname                          | contextid | contextlevel | contextinstanceid | link                                              | courseid | timecreated |
      +--------+------------------------------------+-----------+--------------+-------------------+---------------------------------------------------+----------+-------------+
      | 165540 | \mod_forum\event\discussion_viewed |       143 |           70 |                50 | https://moodle.org/mod/forum/discuss.php?d=272864 |        5 |  1414415569 |
      | 165541 | \mod_forum\event\discussion_viewed |       143 |           70 |                50 | https://moodle.org/mod/forum/discuss.php?d=273627 |        5 |  1414415570 |
      | 165542 | \mod_forum\event\discussion_viewed |       317 |           70 |              2429 | https://moodle.org/mod/forum/discuss.php?d=155986 |       14 |  1414415570 |
      +--------+------------------------------------+-----------+--------------+-------------------+---------------------------------------------------+----------+-------------+
      3 rows in set (0.10 sec)
      

      Attachments

        Issue Links

          Activity

            People

              markn Mark Nelson
              poltawski Dan Poltawski
              Frédéric Massart Frédéric Massart
              Damyon Wiese Damyon Wiese
              Damyon Wiese Damyon Wiese
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Clockify

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