14require_once __DIR__ .
'/Maintenance.php';
24 parent::__construct();
25 $this->
addDescription(
'Rebuild links, text index and recent changes' );
30 return Maintenance::DB_ADMIN;
36 $this->
output(
"** Rebuilding fulltext search index (if you abort "
37 .
"this will break searching; run this script again to fix):\n" );
38 $rebuildText = $this->
createChild( RebuildTextIndex::class,
'rebuildtextindex.php' );
39 $rebuildText->execute();
43 $this->
output(
"\n\n** Rebuilding recentchanges table:\n" );
44 $rebuildRC = $this->
createChild( RebuildRecentchanges::class,
'rebuildrecentchanges.php' );
45 $rebuildRC->execute();
48 $this->
output(
"\n\n** Rebuilding links tables -- this can take a long time. "
49 .
"It should be safe to abort via ctrl+C if you get bored.\n" );
50 $rebuildLinks = $this->
createChild( RefreshLinks::class,
'refreshLinks.php' );
51 $rebuildLinks->execute();
53 $this->
output(
"Done.\n" );
59require_once RUN_MAINTENANCE_IF_MAIN;
Abstract maintenance class for quickly writing and churning out maintenance scripts with minimal effo...
createChild(string $maintClass, ?string $classFile=null)
Returns an instance of the given maintenance script, with all of the current arguments passed to it.
output( $out, $channel=null)
Throw some output to the user.
getReplicaDB(string|false $virtualDomain=false)
addDescription( $text)
Set the description text.
Maintenance script that rebuilds link tracking tables from scratch.
__construct()
Default constructor.
execute()
Do the actual work.
getDbType()
Does the script need different DB access? By default, we give Maintenance scripts normal rights to th...