From: Aaron Schulz Date: Mon, 19 Jan 2009 20:46:31 +0000 (+0000) Subject: Add commit statements after each block X-Git-Tag: 1.31.0-rc.0~43348 X-Git-Url: http://git.cyclocoop.org/%24action?a=commitdiff_plain;h=319e176794fac0f0a7604f36f7e4c4599a45d952;p=lhc%2Fweb%2Fwiklou.git Add commit statements after each block --- diff --git a/maintenance/rebuildFileCache.php b/maintenance/rebuildFileCache.php index 186492498e..7c42d8f1ed 100644 --- a/maintenance/rebuildFileCache.php +++ b/maintenance/rebuildFileCache.php @@ -35,6 +35,7 @@ $end += $BATCH_SIZE - 1; $blockStart = $start; $blockEnd = $start + $BATCH_SIZE - 1; +$dbw = wfGetDB( DB_MASTER ); // Go through each page and save the output while( $blockEnd <= $end ) { // Get the pages @@ -78,6 +79,7 @@ while( $blockEnd <= $end ) { } else { echo "Page {$row->page_id} not cacheable\n"; } + $dbw->commit(); // commit any changes } $blockStart += $BATCH_SIZE; $blockEnd += $BATCH_SIZE;