Commit graph

532 commits

Author SHA1 Message Date
sam marshall
a658b73cd0 MDL-42039 Restore: Avoid unnecessary archive file copy at start
Change the start of restore process so that the archive file can
be passed as a pathnamehash pointing to the Moodle file object,
rather than only as a filename in the temporary directory. This
avoids making an unnecessary copy of the archive file, which can
take a long time (and potentially cause a timeout) in the case
of multi-gigabyte backups.
2013-10-10 10:56:30 +08:00
sam marshall
1cd39657b5 MDL-42039 Restore: Add progress reporting to directory deletion
Deleting directories at the end of backup can take a long time if
there are many directories (potentially up to 65536 file
directories). This change reports progress while deleting
directories to avoid timeout.
2013-10-10 10:56:30 +08:00
sam marshall
37ff843d7d MDL-42039 Restore: Add progress reporting between files in resource
When a resource contains a very large number of (presumably small)
files, we should display progress between each file so that it
doesn't time out.
2013-10-10 10:56:30 +08:00
sam marshall
02da69214f MDL-42039 Restore: Prevent adding too many form fields at once
This change relates to the Moodle forms used to select activities
in the restore process.

If you add too many form fields at once, it takes a very long time
during which we can't report progress. But adding fields in smaller
groups takes longer overall, so it's a tough balance. This change
splits the adds into groups of 1,000, reporting progress between each.
2013-10-10 10:56:29 +08:00
Damyon Wiese
370058d8fb Merge branch 'MDL-41838-master' of git://github.com/sammarshallou/moodle
Conflicts:
	lib/upgrade.txt
2013-10-10 10:49:11 +08:00
Damyon Wiese
f0ae8d7a66 Merge branch 'MDL-38196-master' of git://github.com/sammarshallou/moodle
Conflicts:
	backup/backup.php
	theme/bootstrapbase/style/moodle.css
2013-10-10 09:31:33 +08:00
sam marshall
39e5102f8b MDL-41838 Backup/restore: Support .tar.gz format for .mbz (2 of 2)
The new experimental setting enabletgzbackups allows backups to be
created so that the internal format for .mbz files is .tar.gz.

Restore transparently supports .mbz files with either internal
formats (.zip or .tar.gz).

The .tar.gz format has the following benefits for backup:
- Supports larger files (no limit on total size, 8GB on single file
  vs. 4GB limit on total size)
- Compresses text better, resulting in smaller .mbz files.
- Reports progress regularly during compression of single files,
  reducing the chance of timeouts during backups that include a
  very large file.

Time performance may also be improved although I haven't done a
direct comparison.
2013-10-08 13:04:49 +01:00
sam marshall
77b3d9dfdf MDL-38196 Backup/restore: Display log if non-empty
When doing a backup or restore operation with the normal user interface,
if there is anything in the backup/restore log, it will now be displayed
at the end of the process below the Continue button.

If you have developer debugging enabled, it sets the display level to
LOG_DEBUG and there will always be content in the log. Otherwise, it
uses LOG_INFO which generally means the log is empty, and nothing
displays (no visible change for users).
2013-10-08 11:00:11 +01:00
Dan Poltawski
4f0eaf18f4 Merge branch 'MDL-40493-master' of git://github.com/damyon/moodle
Conflicts:
	lib/db/install.xml
	lib/db/upgrade.php
	version.php
2013-10-08 16:42:17 +08:00
sam marshall
e555a4439f MDL-41722 Backup: Very large course times out on user interface pages
Adds 'Preparing page display' progress bars for user interface pages
if they take a long time to display.

Also adds changes where other parts of the backup progress timed out on
long backups. After this change, and MDL-41838, it is finally possible on
my dev server to successfully back up the 'XL' test course.
2013-10-04 10:32:13 +01:00
Damyon Wiese
3d27180e94 MDL-40493 User preference: Allow users to set their preferred text editor.
This changes the setting htmleditor in the user table from a 0 or 1 column
to a user preference for the name of their preferred html editor.
2013-10-02 12:49:30 +08:00
Marina Glancy
9e11059326 Merge branch 'MDL-12403-master' of git://github.com/danpoltawski/moodle 2013-09-30 18:04:38 +10:00
Dan Poltawski
2d2489e59e MDL-12403 backup: prevent unset config from being applied 2013-09-26 09:55:13 +08:00
Dan Poltawski
99d5203824 MDL-12403 backup: ability configure default for question bank excludes 2013-09-26 09:55:13 +08:00
Dan Poltawski
6507aaeaff MDL-12403 backup: configure question bank in automated backups 2013-09-26 09:55:12 +08:00
Eloy Lafuente (stronk7)
007b803b4a Merge branch 'MDL-38192-master' of git://github.com/sammarshallou/moodle 2013-09-25 00:27:57 +02:00
Eloy Lafuente (stronk7)
dd0fa1adb1 Merge branch 'wip-MDL-41937-master' of git://github.com/marinaglancy/moodle 2013-09-24 14:05:10 +02:00
Marina Glancy
c3a994aeef MDL-41937 tests: reset time limit after test 2013-09-24 20:53:49 +10:00
Marina Glancy
84128f46b2 Merge branch 'MDL-41087-master' of git://github.com/sammarshallou/moodle 2013-09-24 16:29:00 +10:00
Marina Glancy
d9fd72feb5 Merge branch 'MDL-41669-master' of git://github.com/sammarshallou/moodle 2013-09-24 11:48:49 +10:00
sam marshall
88372410f5 MDL-38192 Backup and restore: Allow selection by activity type
Add to the existing 'select all/none' JavaScript so that users can choose
to select or deselect everything of a certain module (e.g. deselect all
forums).
2013-09-18 14:27:54 +01:00
Eloy Lafuente (stronk7)
cfcd93dd11 Merge branch 'MDL-41728-master' of git://github.com/sammarshallou/moodle 2013-09-17 21:17:05 +02:00
sam marshall
4fb31ae6cd MDL-41669 Restore: Progress bar needs to include more tasks
1. Changes progress bar code to allow headings for progress bar (so users have
   some clue what's going on if a page has more than one progress bar).
2. Changes restore code so that a progress bar can display during pre-checks if
   they take longer than 5 seconds.
3. Changes pre-check and restore code so that, in various points where the system
   can take a long time within an individual step, intederminate progress is
   indicated and it won't time out.
2013-09-16 17:18:12 +01:00
sam marshall
6a0189eb3f MDL-41817 Backup/restore without blocks gives error
Also applies to various other situations where backup includes 0 of
something. This was caused by a problem in the progress-tracking code.
2013-09-16 17:11:40 +01:00
sam marshall
2a70b70c44 MDL-41087 Backup: add progress tracking in slow steps
Adds calls to the new backup progress tracking API within various steps of the
backup system - previously it only tracked progress between steps, but some steps
can themselves be slow. This ensures the system displays progress (either by
moving the progress bar if possible, or by making the wibbler below it pulsate)
during nearly all of the backup process.
2013-09-13 11:07:23 +01:00
sam marshall
39ca3044ea MDL-41728 Backup: Unnecessary use of in_array in base_plan
Remove unnecessary use of in_array which causes performance problems
when loading the plan for very large courses.
2013-09-11 14:32:14 +01:00
Dan Poltawski
30d6c394e2 Merge branch 'MDL-41147-master' of git://github.com/sammarshallou/moodle 2013-09-10 10:27:59 +08:00
Damyon Wiese
934c70040c Merge branch 'MDL-41253-master' of git://github.com/sammarshallou/moodle 2013-09-10 09:03:42 +08:00
Sam Hemelryk
68d3e7682a Merge branch 'MDL-41167-master' of git://github.com/sammarshallou/moodle 2013-09-10 10:31:59 +12:00
sam marshall
a7a64d774a MDL-41253 Restore: Mechanism to display progress during UI stages 2013-09-09 12:42:07 +01:00
sam marshall
6b5a7ce833 MDL-41167 Restore: Large course times out on Review page 2013-09-05 17:32:34 +01:00
sam marshall
347e663814 MDL-41147 Restore: Large course fails due to time limit when unzipping 2013-09-05 17:22:30 +01:00
sam marshall
7b4dbf0fa2 MDL-41163 Restore: Large course restore timeout on schema page 2013-09-05 17:06:59 +01:00
Eloy Lafuente (stronk7)
df7995e3a0 Merge branch 'MDL-41146-master' of git://github.com/sammarshallou/moodle 2013-09-04 01:01:19 +02:00
Eloy Lafuente (stronk7)
58c80b03a8 Merge branch 'MDL-40566_master' of git://github.com/dmonllao/moodle 2013-09-03 20:38:53 +02:00
Damyon Wiese
be62e59a93 Merge branch 'mdl26_MDL-41403_backup_reduce_memory_usage' of https://github.com/brki/moodle 2013-09-03 16:18:36 +08:00
David Monllao
fcc0b5b920 MDL-40566 behat: Update features using the new options 2013-09-03 10:31:57 +08:00
Eloy Lafuente (stronk7)
e034d84c48 Merge branch 'MDL-38190-master' of git://github.com/sammarshallou/moodle
Conflicts:
	backup/import.php
	theme/bootstrapbase/style/moodle.css
2013-09-02 16:56:50 +02:00
Brian King
07dffdf5f5 MDL-41403 Backup: reduce memory usage when searching for courses / categories
Also makes a few existing comments in the changed code area adhere to coding standards.
2013-08-28 12:59:16 +02:00
Damyon Wiese
37e2954e19 Merge branch 'MDL-41401-master' of git://github.com/danpoltawski/moodle 2013-08-27 15:09:21 +08:00
Damyon Wiese
a6163e7a5f MDL-31093 Scorm course format: Remove behat tests
The scorm course format has been removed so we don't need to test it anymore.
2013-08-27 13:26:47 +08:00
Dan Poltawski
e820d50791 Merge branch 'MDL-37211_master' of https://github.com/nadavkav/moodle 2013-08-27 11:54:28 +08:00
Dan Poltawski
007cbfe03e MDL-41401 backup: fix misnamed test method 2013-08-23 15:09:12 +08:00
Mark Nelson
6d8627cb6b MDL-36126 backup: changed the message column in the table backup_logs to a text field to prevent DB errors 2013-08-23 11:40:36 +08:00
Damyon Wiese
74df2951d1 Revert "MDL-39876 Change get_record('course') calls to get_course"
This reverts commit ab7632b74c.
2013-08-21 13:42:30 +08:00
Sam Hemelryk
6eee89bc8f Merge branch 'MDL-39876-master' of git://github.com/sammarshallou/moodle
Conflicts:
	course/lib.php
2013-08-21 12:08:46 +12:00
Dan Poltawski
91a888df34 Merge branch 'MDL-39957_master' of https://github.com/markn86/moodle 2013-08-20 12:38:08 +08:00
sam marshall
f06abc2ac1 MDL-38190 (3) Backup/restore: Progress display in main user interface 2013-08-16 16:28:04 +01:00
sam marshall
2531ae2922 MDL-38190 (2) Backup/restore: Progress tracking for tasks and steps 2013-08-16 10:50:36 +01:00
sam marshall
16cd708835 MDL-38190 (1) Backup/restore: Progress tracking API 2013-08-16 10:50:35 +01:00