Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Deferred
-
3.4
-
None
Description
From dmonllao:
DavidMonllao, [Oct 10, 2017 at 10:42:06 PM]
...have you noticed any performance issue being logged as admin in a course with the calendar block in screen?
I've loaded a real site database (around 5000 courses) and it takes me more than 1 minute to load moodle index
more info: it needs like 300.000 db queries to load the page; I am logged as admin and there is a calendar block in the frontpage; I've tried to track wtf is going on and I've seen that most queries are "SELECT * FROM mdl_context WHERE contextlevel = ? AND instanceid = ?"; debugging a bit more it seems that the problem comes from calendar_get_view and month_exporter, week_exporter and day_exporter; you can see the trace in https://pastebin.com/xkqzxANa
the sql dump I've used is https://drive.google.com/drive/u/1/folders/0B0DMrAQRleD4YnhfdXNFdm41dzA
I've just deleted calendar_month record from mdl_block_instances and the frontpage loads instantly (I couldn't do it using the web UI)
Attachments
Issue Links
- has a non-specific relationship to
-
MDL-63285 Slow fetching of calendar events
-
- Closed
-
- has been marked as being related by
-
MDL-60826 Memory exhaustion error when trying to add/edit calendar event as admin
-
- Closed
-
- Testing discovered
-
MDL-60996 Loading calendar events for user in huge number of courses errors
-
- Closed
-
- will be (partly) resolved by
-
MDL-60564 The day_exporter class unnecessarily defines and calls get_course_filter_selector()
-
- Closed
-
-
MDL-60958 Stop loading parent record in repeat collection
-
- Closed
-
-
MDL-60959 Remove redundancy in calendar exporters for calendar month view
-
- Closed
-
-
MDL-60960 Check course enrolment later in event factory early bailout check
-
- Closed
-
-
MDL-60961 Batch load groups in calendar_set_filters
-
- Closed
-
-
MDL-60962 Load the calendar blocks after page load
-
- Closed
-
-
MDL-60963 Use related cache to load course modules during event export
-
- Closed
-
-
MDL-60966 Allow contexts to be passed into external format functions
-
- Closed
-