Issue Details (XML | Word | Printable)

Key: MDL-12594
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Eloy Lafuente (stronk7)
Reporter: Dan Poltawski
Votes: 3
Watchers: 3
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle

Restoring a course with 400 users enrolled costs 13k DB queries

Created: 16/Dec/07 09:15 AM   Updated: 13/May/08 04:48 PM
Return to search
Component/s: Backup
Affects Version/s: 1.9
Fix Version/s: 1.9.1

File Attachments: 1. Zip Archive backup-cf101-20080121-1619.zip (74 kB)
2. File restorelib.php (393 kB)

Issue Links:
Dependency
 

Participants: Dan Poltawski, Eloy Lafuente (stronk7), Pat B. and Petr Skoda
Security Level: None
QA Assignee: Petr Skoda
Resolved date: 13/May/08
Affected Branches: MOODLE_19_STABLE
Fixed Branches: MOODLE_19_STABLE


 Description  « Hide
Ouch, was just playing with a course with 400 users and restoring it cost 13k db queries!

I quickly put a few mtraces in restore_create_users with $PERF->dbqueries and it seems to cost about 6000 queries on itself to end up not doing much.

 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
Eloy Lafuente (stronk7) committed 1 file to 'Moodle CVS' on branch 'MOODLE_19_STABLE' - 13/May/08 02:00 AM
user preferences are not restored if user exists. MDL-12594
MODIFY backup/restorelib.php   Rev. 1.283.2.40    (+2 -1 lines)
Eloy Lafuente (stronk7) committed 1 file to 'Moodle CVS' - 13/May/08 02:01 AM
user preferences are not restored if user exists. MDL-12594 ; merged from 19_STABLE
MODIFY backup/restorelib.php   Rev. 1.328    (+2 -1 lines)