Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.3.x will end 7 October 2024 (12 months).
  • Bug fixes for security issues in 4.3.x will end 21 April 2025 (18 months).
  • PHP version: minimum PHP 8.0.0 Note: minimum PHP version has increased since Moodle 4.1. PHP 8.2.x is supported too.

Differences Between: [Versions 39 and 403]

Export db content to file.

Copyright: 2008 Petr Skoda {@link http://skodak.org/}
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 209 lines (7 kb)
Included or required: 4 times
Referenced: 0 times
Includes or requires: 0 files

Defines 6 functions


Functions that are not part of a class:

tool_dbtransfer_export_xml_database($description, $mdb)   X-Ref
Initiate database export.

param: string $description
param: moodle_database $mdb
return: does not return, calls die()

tool_dbtransfer_transfer_database(moodle_database $sourcedb, moodle_database $targetdb, progress_trace $feedback = null)   X-Ref
Initiate database transfer.

param: moodle_database $sourcedb
param: moodle_database $targetdb
param: progress_trace $feedback
return: void

tool_dbtransfer_rebuild_target_log_actions(moodle_database $target, progress_trace $feedback = null)   X-Ref
Very hacky function for rebuilding of log actions in target database.

param: moodle_database $target
param: progress_trace $feedback
return: void

tool_dbtransfer_get_drivers()   X-Ref
Returns list of fully working database drivers present in system.

return: array

tool_dbtransfer_create_maintenance_file()   X-Ref
Create CLI maintenance file to prevent all access.


tool_dbtransfer_maintenance_callback()   X-Ref
This callback is responsible for unsetting maintenance mode
if the migration is interrupted.