MediaWiki
REL1_21
|
Class for handling database updates. More...
Public Member Functions | |
addExtensionField ($tableName, $columnName, $sqlPath) | |
addExtensionIndex ($tableName, $indexName, $sqlPath) | |
addExtensionTable ($tableName, $sqlPath) | |
Convenience wrapper for addExtensionUpdate() when adding a new table (which is the most common usage of updaters in an extension) | |
addExtensionUpdate (array $update) | |
Add a new update coming from an extension. | |
addPostDatabaseUpdateMaintenance ($class) | |
Add a maintenance script to be run after the database updates are complete. | |
appendLine ($line) | |
Append a line to the open filehandle. | |
copyFile ($filename) | |
Append an SQL fragment to the open file handle. | |
doUpdates ($what=array( 'core', 'extensions', 'stats')) | |
Do all the updates. | |
dropExtensionField ($tableName, $columnName, $sqlPath) | |
dropExtensionIndex ($tableName, $indexName, $sqlPath) | |
Drop an index from an extension table. | |
dropExtensionTable ($tableName, $sqlPath) | |
dropTable ($table, $patch=false, $fullpath=false) | |
If the specified table exists, drop it, or execute the patch if one is provided. | |
getDB () | |
Get a database connection to run updates. | |
getPostDatabaseUpdateMaintenance () | |
insertUpdateRow ($key, $val=null) | |
Helper function: Add a key to the updatelog table Obviously, only use this for updates that occur after the updatelog table was created! | |
modifyExtensionField ($tableName, $fieldName, $sqlPath) | |
modifyField ($table, $field, $patch, $fullpath=false) | |
Modify an existing field. | |
output ($str) | |
Output some text. | |
purgeCache () | |
Purge the objectcache table. | |
renameExtensionIndex ($tableName, $oldIndexName, $newIndexName, $sqlPath, $skipBothIndexExistWarning=false) | |
Rename an index on an extension table. | |
tableExists ($tableName) | |
updateRowExists ($key) | |
Helper function: check if the given key is present in the updatelog table. | |
Static Public Member Functions | |
static | newForDB (&$db, $shared=false, $maintenance=null) |
Protected Member Functions | |
__construct (DatabaseBase &$db, $shared, Maintenance $maintenance=null) | |
Constructor. | |
addField ($table, $field, $patch, $fullpath=false) | |
Add a new field to an existing table. | |
addIndex ($table, $index, $patch, $fullpath=false) | |
Add a new index to an existing table. | |
addTable ($name, $patch, $fullpath=false) | |
Add a new table to the database. | |
applyPatch ($path, $isFullPath=false, $msg=null) | |
Applies a SQL patch. | |
canUseNewUpdatelog () | |
Updatelog was changed in 1.17 to have a ul_value column so we can record more information about what kind of updates we've done (that's what this class does). | |
checkStats () | |
Check the site_stats table is not properly populated. | |
disableContentHandlerUseDB () | |
Turns off content handler fields during parts of the upgrade where they aren't available. | |
doActiveUsersInit () | |
Sets the number of active users in the site_stats table. | |
doCollationUpdate () | |
Update CategoryLinks collation. | |
doLogSearchPopulation () | |
Migrate log params to new table and index for searching. | |
doLogUsertextPopulation () | |
Populates the log_user_text field in the logging table. | |
doMigrateUserOptions () | |
Migrates user options from the user table blob to user_properties. | |
doTable ($name) | |
Returns whether updates should be executed on the database table $name. | |
doUpdateTranscacheField () | |
Updates the timestamps in the transcache table. | |
dropField ($table, $field, $patch, $fullpath=false) | |
Drop a field from an existing table. | |
dropIndex ($table, $index, $patch, $fullpath=false) | |
Drop an index from an existing table. | |
enableContentHandlerUseDB () | |
Turns content handler fields back on. | |
getCoreUpdateList () | |
Get an array of updates to perform on the database. | |
getExtensionUpdates () | |
Get the list of extension-defined updates. | |
getOldGlobalUpdates () | |
Before 1.17, we used to handle updates via stuff like $wgExtNewTables/Fields/Indexes. | |
rebuildLocalisationCache () | |
Rebuilds the localisation cache. | |
renameIndex ($table, $oldIndex, $newIndex, $skipBothIndexExistWarning, $patch, $fullpath=false) | |
Rename an index from an existing table. | |
setAppliedUpdates ($version, $updates=array()) | |
Protected Attributes | |
DatabaseBase | $db |
Handle to the database subclass. | |
array | $extensionUpdates = array() |
List of extension-provided database updates. | |
Filehandle | $fileHandle = null |
File handle for SQL output. | |
$postDatabaseUpdateMaintenance | |
Scripts to run after database update Should be a subclass of LoggedUpdateMaintenance. | |
$shared = false | |
bool | $skipSchema = false |
Flag specifying whether or not to skip schema (e.g. | |
array | $updates = array() |
Array of updates to perform on the database. | |
array | $updatesSkipped = array() |
Array of updates that were skipped. | |
$wgContentHandlerUseDB = true | |
Hold the value of $wgContentHandlerUseDB during the upgrade. | |
Private Member Functions | |
initOldGlobals () | |
Initialize all of the old globals. | |
loadExtensions () | |
Loads LocalSettings.php, if needed, and initialises everything needed for LoadExtensionSchemaUpdates hook. | |
runUpdates (array $updates, $passSelf) | |
Helper function for doUpdates() | |
writeSchemaUpdateFile ($schemaUpdate=array()) |
Class for handling database updates.
Roughly based off of updaters.inc, with a few improvements :)
Definition at line 33 of file DatabaseUpdater.php.
DatabaseUpdater::__construct | ( | DatabaseBase &$ | db, |
$ | shared, | ||
Maintenance $ | maintenance = null |
||
) | [protected] |
Constructor.
$db | DatabaseBase object to perform updates on | |
bool | $shared | Whether to perform updates on shared tables |
$maintenance | Maintenance Maintenance object which created us |
Definition at line 97 of file DatabaseUpdater.php.
DatabaseUpdater::addExtensionField | ( | $ | tableName, |
$ | columnName, | ||
$ | sqlPath | ||
) |
$tableName | string |
$columnName | string |
$sqlPath | string |
Definition at line 242 of file DatabaseUpdater.php.
DatabaseUpdater::addExtensionIndex | ( | $ | tableName, |
$ | indexName, | ||
$ | sqlPath | ||
) |
$tableName | string |
$indexName | string |
$sqlPath | string |
Definition at line 230 of file DatabaseUpdater.php.
DatabaseUpdater::addExtensionTable | ( | $ | tableName, |
$ | sqlPath | ||
) |
Convenience wrapper for addExtensionUpdate() when adding a new table (which is the most common usage of updaters in an extension)
string | $tableName | Name of table to create |
string | $sqlPath | Full path to the schema file |
Definition at line 219 of file DatabaseUpdater.php.
DatabaseUpdater::addExtensionUpdate | ( | array $ | update | ) |
Add a new update coming from an extension.
This should be called by extensions while executing the LoadExtensionSchemaUpdates hook.
array | $update | the update to run. Format is the following: first item is the callback function, it also can be a simple string with the name of a function in this class, following elements are parameters to the function. Note that callback functions will receive this object as first parameter. |
Definition at line 206 of file DatabaseUpdater.php.
DatabaseUpdater::addField | ( | $ | table, |
$ | field, | ||
$ | patch, | ||
$ | fullpath = false |
||
) | [protected] |
Add a new field to an existing table.
string | $table | Name of the table to modify |
string | $field | Name of the new field |
string | $patch | Path to the patch file |
$fullpath | Boolean Whether to treat $patch path as a relative or not |
Definition at line 669 of file DatabaseUpdater.php.
DatabaseUpdater::addIndex | ( | $ | table, |
$ | index, | ||
$ | patch, | ||
$ | fullpath = false |
||
) | [protected] |
Add a new index to an existing table.
string | $table | Name of the table to modify |
string | $index | Name of the new index |
string | $patch | Path to the patch file |
$fullpath | Boolean Whether to treat $patch path as a relative or not |
Definition at line 693 of file DatabaseUpdater.php.
Add a maintenance script to be run after the database updates are complete.
Script should subclass LoggedUpdateMaintenance
string | $class | Name of a Maintenance subclass |
Definition at line 328 of file DatabaseUpdater.php.
DatabaseUpdater::addTable | ( | $ | name, |
$ | patch, | ||
$ | fullpath = false |
||
) | [protected] |
Add a new table to the database.
string | $name | Name of the new table |
string | $patch | Path to the patch file |
$fullpath | Boolean Whether to treat $patch path as a relative or not |
Definition at line 647 of file DatabaseUpdater.php.
DatabaseUpdater::appendLine | ( | $ | line | ) |
Append a line to the open filehandle.
The line is assumed to be a complete SQL statement.
This is used as a callback for for sourceLine().
string | $line | text to append to the file |
MWException |
Definition at line 600 of file DatabaseUpdater.php.
DatabaseUpdater::applyPatch | ( | $ | path, |
$ | isFullPath = false , |
||
$ | msg = null |
||
) | [protected] |
Applies a SQL patch.
string | $path | Path to the patch file |
$isFullPath | Boolean Whether to treat $path as a relative or not | |
string | $msg | Description of the patch |
Definition at line 616 of file DatabaseUpdater.php.
Referenced by PostgresUpdater\addInterwikiType(), PostgresUpdater\addPgExtIndex(), MysqlUpdater\checkBin(), PostgresUpdater\checkIwlPrefix(), PostgresUpdater\checkPageDeletedTrigger(), PostgresUpdater\checkRevUserFkey(), PostgresUpdater\convertArchive2(), MysqlUpdater\doBacklinkingIndicesUpdate(), MysqlUpdater\doCategorylinksIndicesUpdate(), MysqlUpdater\doClFieldsUpdate(), SqliteUpdater\doEnableProfiling(), MysqlUpdater\doEnableProfiling(), MysqlUpdater\doFilearchiveIndicesUpdate(), MysqlUpdater\doFixAncientImagelinks(), MysqlUpdater\doIndexUpdate(), MysqlUpdater\doInterwikiUpdate(), MysqlUpdater\doLangLinksLengthUpdate(), MysqlUpdater\doMaybeProfilingMemoryUpdate(), MysqlUpdater\doPagelinksUpdate(), OracleUpdater\doRemoveNotNullEmptyDefaults2(), MysqlUpdater\doRestrictionsUpdate(), MysqlUpdater\doTemplatelinksUpdate(), MysqlUpdater\doUniquePlTlIl(), MysqlUpdater\doUpdateMimeMinorField(), MysqlUpdater\doUserGroupsUpdate(), MysqlUpdater\doUserNewTalkTimestampNotNull(), MysqlUpdater\doUserUniqueUpdate(), MysqlUpdater\doWatchlistNull(), MysqlUpdater\renameEuWikiId(), PostgresUpdater\renameTable(), SqliteUpdater\sqliteInitialIndexes(), SqliteUpdater\sqliteSetupSearchindex(), and PostgresUpdater\tsearchFixes().
DatabaseUpdater::canUseNewUpdatelog | ( | ) | [protected] |
Updatelog was changed in 1.17 to have a ul_value column so we can record more information about what kind of updates we've done (that's what this class does).
Pre-1.17 wikis won't have this column, and really old wikis might not even have updatelog at all
Definition at line 500 of file DatabaseUpdater.php.
DatabaseUpdater::checkStats | ( | ) | [protected] |
Check the site_stats table is not properly populated.
Definition at line 874 of file DatabaseUpdater.php.
Referenced by doUpdates().
DatabaseUpdater::copyFile | ( | $ | filename | ) |
Append an SQL fragment to the open file handle.
string | $filename | File name to open |
Definition at line 584 of file DatabaseUpdater.php.
References array().
DatabaseUpdater::disableContentHandlerUseDB | ( | ) | [protected] |
Turns off content handler fields during parts of the upgrade where they aren't available.
Definition at line 1005 of file DatabaseUpdater.php.
DatabaseUpdater::doActiveUsersInit | ( | ) | [protected] |
Sets the number of active users in the site_stats table.
Definition at line 893 of file DatabaseUpdater.php.
References array().
DatabaseUpdater::doCollationUpdate | ( | ) | [protected] |
Update CategoryLinks collation.
Definition at line 956 of file DatabaseUpdater.php.
DatabaseUpdater::doLogSearchPopulation | ( | ) | [protected] |
Migrate log params to new table and index for searching.
Definition at line 927 of file DatabaseUpdater.php.
DatabaseUpdater::doLogUsertextPopulation | ( | ) | [protected] |
Populates the log_user_text field in the logging table.
Definition at line 911 of file DatabaseUpdater.php.
DatabaseUpdater::doMigrateUserOptions | ( | ) | [protected] |
Migrates user options from the user table blob to user_properties.
Definition at line 979 of file DatabaseUpdater.php.
DatabaseUpdater::doTable | ( | $ | name | ) | [protected] |
Returns whether updates should be executed on the database table $name.
Updates will be prevented if the table is a shared table and it is not specified to run updates on shared tables.
string | $name | table name |
Definition at line 513 of file DatabaseUpdater.php.
Referenced by MysqlUpdater\checkBin(), MysqlUpdater\doEnableProfiling(), MysqlUpdater\doInterwikiUpdate(), MysqlUpdater\doMaybeProfilingMemoryUpdate(), MysqlUpdater\doUserGroupsUpdate(), MysqlUpdater\doUserNewTalkTimestampNotNull(), MysqlUpdater\doUserUniqueUpdate(), and MysqlUpdater\indexHasField().
DatabaseUpdater::doUpdates | ( | $ | what = array( 'core', 'extensions', 'stats' ) | ) |
Do all the updates.
array | $what | what updates to perform |
Reimplemented in OracleUpdater.
Definition at line 374 of file DatabaseUpdater.php.
References checkStats(), getCoreUpdateList(), getExtensionUpdates(), getOldGlobalUpdates(), global, purgeCache(), rebuildLocalisationCache(), runUpdates(), setAppliedUpdates(), updates(), and writeSchemaUpdateFile().
DatabaseUpdater::doUpdateTranscacheField | ( | ) | [protected] |
Updates the timestamps in the transcache table.
Definition at line 943 of file DatabaseUpdater.php.
DatabaseUpdater::dropExtensionField | ( | $ | tableName, |
$ | columnName, | ||
$ | sqlPath | ||
) |
$tableName | string |
$columnName | string |
$sqlPath | string |
Definition at line 254 of file DatabaseUpdater.php.
DatabaseUpdater::dropExtensionIndex | ( | $ | tableName, |
$ | indexName, | ||
$ | sqlPath | ||
) |
Drop an index from an extension table.
string | $tableName | The table name |
string | $indexName | The index name |
string | $sqlPath | The path to the SQL change path |
Definition at line 267 of file DatabaseUpdater.php.
DatabaseUpdater::dropExtensionTable | ( | $ | tableName, |
$ | sqlPath | ||
) |
$tableName | string |
$sqlPath | string |
Definition at line 278 of file DatabaseUpdater.php.
DatabaseUpdater::dropField | ( | $ | table, |
$ | field, | ||
$ | patch, | ||
$ | fullpath = false |
||
) | [protected] |
Drop a field from an existing table.
string | $table | Name of the table to modify |
string | $field | Name of the old field |
string | $patch | Path to the patch file |
$fullpath | Boolean Whether to treat $patch path as a relative or not |
Definition at line 717 of file DatabaseUpdater.php.
DatabaseUpdater::dropIndex | ( | $ | table, |
$ | index, | ||
$ | patch, | ||
$ | fullpath = false |
||
) | [protected] |
Drop an index from an existing table.
string | $table | Name of the table to modify |
string | $index | Name of the index |
string | $patch | Path to the patch file |
$fullpath | Boolean: Whether to treat $patch path as a relative or not |
Reimplemented in PostgresUpdater.
Definition at line 739 of file DatabaseUpdater.php.
DatabaseUpdater::dropTable | ( | $ | table, |
$ | patch = false , |
||
$ | fullpath = false |
||
) |
If the specified table exists, drop it, or execute the patch if one is provided.
Public
$table | string |
$patch | string|false |
$fullpath | bool |
Definition at line 805 of file DatabaseUpdater.php.
DatabaseUpdater::enableContentHandlerUseDB | ( | ) | [protected] |
Turns content handler fields back on.
Definition at line 1018 of file DatabaseUpdater.php.
DatabaseUpdater::getCoreUpdateList | ( | ) | [abstract, protected] |
Get an array of updates to perform on the database.
Should return a multi-dimensional array. The main key is the MediaWiki version (1.12, 1.13...) with the values being arrays of updates, identical to how updaters.inc did it (for now)
Reimplemented in PostgresUpdater, OracleUpdater, MysqlUpdater, and SqliteUpdater.
Referenced by doUpdates().
Get a database connection to run updates.
Definition at line 172 of file DatabaseUpdater.php.
DatabaseUpdater::getExtensionUpdates | ( | ) | [protected] |
Get the list of extension-defined updates.
Definition at line 337 of file DatabaseUpdater.php.
Referenced by doUpdates().
DatabaseUpdater::getOldGlobalUpdates | ( | ) | [protected] |
Before 1.17, we used to handle updates via stuff like $wgExtNewTables/Fields/Indexes.
This is nasty :) We refactored a lot of this in 1.17 but we want to remain back-compatible for a while. So load up these old global-based things into our update list.
Reimplemented in PostgresUpdater.
Definition at line 533 of file DatabaseUpdater.php.
Referenced by doUpdates().
DatabaseUpdater::initOldGlobals | ( | ) | [private] |
Initialize all of the old globals.
One day this should all become something much nicer
Definition at line 117 of file DatabaseUpdater.php.
DatabaseUpdater::insertUpdateRow | ( | $ | key, |
$ | val = null |
||
) |
Helper function: Add a key to the updatelog table Obviously, only use this for updates that occur after the updatelog table was created!
string | $key | Name of key to insert |
string | $val | [optional] value to insert along with the key |
Definition at line 482 of file DatabaseUpdater.php.
DatabaseUpdater::loadExtensions | ( | ) | [private] |
Loads LocalSettings.php, if needed, and initialises everything needed for LoadExtensionSchemaUpdates hook.
Definition at line 134 of file DatabaseUpdater.php.
DatabaseUpdater::modifyExtensionField | ( | $ | tableName, |
$ | fieldName, | ||
$ | sqlPath | ||
) |
string | $tableName | The table name |
string | $fieldName | The field to be modified |
string | $sqlPath | The path to the SQL change path |
Definition at line 304 of file DatabaseUpdater.php.
DatabaseUpdater::modifyField | ( | $ | table, |
$ | field, | ||
$ | patch, | ||
$ | fullpath = false |
||
) |
Modify an existing field.
string | $table | name of the table to which the field belongs |
string | $field | name of the field to modify |
string | $patch | path to the patch file |
$fullpath | Boolean: whether to treat $patch path as a relative or not |
Definition at line 836 of file DatabaseUpdater.php.
static DatabaseUpdater::newForDB | ( | &$ | db, |
$ | shared = false , |
||
$ | maintenance = null |
||
) | [static] |
MWException |
DatabaseBase | $db | |
bool | $shared | |
null | $maintenance |
Definition at line 157 of file DatabaseUpdater.php.
Referenced by DatabaseSqliteTest\prepareDB().
DatabaseUpdater::output | ( | $ | str | ) |
Output some text.
If we're running from web, escape the text first.
string | $str | Text to output |
Definition at line 181 of file DatabaseUpdater.php.
References $wgCommandLineMode, echo, and global.
Referenced by PostgresUpdater\addPgExtIndex(), PostgresUpdater\addPgField(), PostgresUpdater\addPgIndex(), PostgresUpdater\addSequence(), PostgresUpdater\changeField(), PostgresUpdater\changeFkeyDeferrable(), PostgresUpdater\changeNullableField(), MysqlUpdater\checkBin(), PostgresUpdater\checkIndex(), PostgresUpdater\checkOiDeleted(), PostgresUpdater\checkOiNameConstraint(), PostgresUpdater\checkPageDeletedTrigger(), PostgresUpdater\checkRevUserFkey(), PostgresUpdater\convertArchive2(), MysqlUpdater\doCategoryPopulation(), MysqlUpdater\doClFieldsUpdate(), MysqlUpdater\doFixAncientImagelinks(), MysqlUpdater\doIndexUpdate(), MysqlUpdater\doInterwikiUpdate(), MysqlUpdater\doLangLinksLengthUpdate(), MysqlUpdater\doMaybeProfilingMemoryUpdate(), MysqlUpdater\doNamespaceSize(), MysqlUpdater\doPagelinksUpdate(), MysqlUpdater\doPageRandomUpdate(), MysqlUpdater\doPopulateParentId(), MysqlUpdater\doRestrictionsUpdate(), MysqlUpdater\doSchemaRestructuring(), MysqlUpdater\doTemplatelinksUpdate(), MysqlUpdater\doUniquePlTlIl(), MysqlUpdater\doUpdateMimeMinorField(), MysqlUpdater\doUserGroupsUpdate(), MysqlUpdater\doUserNewTalkTimestampNotNull(), MysqlUpdater\doUserUniqueUpdate(), MysqlUpdater\doWatchlistNull(), MysqlUpdater\doWatchlistUpdate(), PostgresUpdater\dropIndex(), MysqlUpdater\indexHasField(), MysqlUpdater\renameEuWikiId(), PostgresUpdater\renameIndex(), PostgresUpdater\renameSequence(), PostgresUpdater\renameTable(), PostgresUpdater\setDefault(), SqliteUpdater\sqliteInitialIndexes(), and SqliteUpdater\sqliteSetupSearchindex().
Purge the objectcache table.
Reimplemented in OracleUpdater.
Definition at line 858 of file DatabaseUpdater.php.
Referenced by doUpdates().
DatabaseUpdater::rebuildLocalisationCache | ( | ) | [protected] |
Rebuilds the localisation cache.
Definition at line 990 of file DatabaseUpdater.php.
Referenced by doUpdates().
DatabaseUpdater::renameExtensionIndex | ( | $ | tableName, |
$ | oldIndexName, | ||
$ | newIndexName, | ||
$ | sqlPath, | ||
$ | skipBothIndexExistWarning = false |
||
) |
Rename an index on an extension table.
string | $tableName | The table name |
string | $oldIndexName | The old index name |
string | $newIndexName | The new index name |
$skipBothIndexExistWarning | Boolean: Whether to warn if both the old and the new indexes exist. [facultative; by default, false] | |
string | $sqlPath | The path to the SQL change path |
Definition at line 293 of file DatabaseUpdater.php.
DatabaseUpdater::renameIndex | ( | $ | table, |
$ | oldIndex, | ||
$ | newIndex, | ||
$ | skipBothIndexExistWarning, | ||
$ | patch, | ||
$ | fullpath = false |
||
) | [protected] |
Rename an index from an existing table.
string | $table | Name of the table to modify |
string | $oldIndex | Old name of the index |
string | $newIndex | New name of the index |
$skipBothIndexExistWarning | Boolean: Whether to warn if both the old and the new indexes exist. | |
string | $patch | Path to the patch file |
$fullpath | Boolean: Whether to treat $patch path as a relative or not |
Reimplemented in PostgresUpdater.
Definition at line 763 of file DatabaseUpdater.php.
DatabaseUpdater::runUpdates | ( | array $ | updates, |
$ | passSelf | ||
) | [private] |
Helper function for doUpdates()
array | $updates | of updates to run |
$passSelf | Boolean: whether to pass this object we calling external functions |
Definition at line 418 of file DatabaseUpdater.php.
Referenced by doUpdates().
DatabaseUpdater::setAppliedUpdates | ( | $ | version, |
$ | updates = array() |
||
) | [protected] |
$version | |
$updates | array |
Definition at line 445 of file DatabaseUpdater.php.
Referenced by doUpdates().
DatabaseUpdater::tableExists | ( | $ | tableName | ) |
$tableName | string |
Definition at line 315 of file DatabaseUpdater.php.
DatabaseUpdater::updateRowExists | ( | $ | key | ) |
Helper function: check if the given key is present in the updatelog table.
Obviously, only use this for updates that occur after the updatelog table was created!
string | $key | Name of the key to check for |
Definition at line 465 of file DatabaseUpdater.php.
Referenced by MysqlUpdater\doCategoryPopulation(), MysqlUpdater\doClFieldsUpdate(), MysqlUpdater\doPopulateParentId(), MysqlUpdater\doUpdateMimeMinorField(), SqliteUpdater\sqliteInitialIndexes(), and SqliteUpdater\sqliteSetupSearchindex().
DatabaseUpdater::writeSchemaUpdateFile | ( | $ | schemaUpdate = array() | ) | [private] |
Writes the schema updates desired to a file for the DB Admin to run.
Definition at line 355 of file DatabaseUpdater.php.
References $updates, array(), and as.
Referenced by doUpdates().
DatabaseBase DatabaseUpdater::$db [protected] |
Handle to the database subclass.
Reimplemented in OracleUpdater, and PostgresUpdater.
Definition at line 56 of file DatabaseUpdater.php.
List of extension-provided database updates.
Definition at line 50 of file DatabaseUpdater.php.
Filehandle DatabaseUpdater::$fileHandle = null [protected] |
File handle for SQL output.
Definition at line 77 of file DatabaseUpdater.php.
DatabaseUpdater::$postDatabaseUpdateMaintenance [protected] |
array( 'DeleteDefaultMessages', 'PopulateRevisionLength', 'PopulateRevisionSha1', 'PopulateImageSha1', 'FixExtLinksProtocolRelative', 'PopulateFilearchiveSha1', )
Scripts to run after database update Should be a subclass of LoggedUpdateMaintenance.
Definition at line 64 of file DatabaseUpdater.php.
DatabaseUpdater::$shared = false [protected] |
Definition at line 58 of file DatabaseUpdater.php.
bool DatabaseUpdater::$skipSchema = false [protected] |
Flag specifying whether or not to skip schema (e.g.
SQL-only) updates.
Definition at line 83 of file DatabaseUpdater.php.
Array of updates to perform on the database.
Definition at line 39 of file DatabaseUpdater.php.
Referenced by PostgresUpdater\getOldGlobalUpdates(), and writeSchemaUpdateFile().
Array of updates that were skipped.
Definition at line 45 of file DatabaseUpdater.php.
DatabaseUpdater::$wgContentHandlerUseDB = true [protected] |
Hold the value of $wgContentHandlerUseDB during the upgrade.
Definition at line 88 of file DatabaseUpdater.php.