r112735 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r112734‎ | r112735 | r112736 >
Date:22:30, 29 February 2012
Author:tstarling
Status:ok
Tags:
Comment:
Fix comment from r54410, add rationale for using MySQL command line pipe
Modified paths:
  • /trunk/phase3/maintenance/populateImageSha1.php (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/populateImageSha1.php
@@ -74,7 +74,10 @@
7575 $imageTable = $dbw->tableName( 'image' );
7676
7777 if ( $method == 'pipe' ) {
78 - // @todo FIXME: Kill this and replace with a second unbuffered DB connection.
 78+ // Opening a pipe allows the SHA-1 operation to be done in parallel
 79+ // with the database write operation, because the writes are queued
 80+ // in the pipe buffer. This can improve performance by up to a
 81+ // factor of 2.
7982 global $wgDBuser, $wgDBserver, $wgDBpassword, $wgDBname;
8083 $cmd = 'mysql -u' . wfEscapeShellArg( $wgDBuser ) .
8184 ' -h' . wfEscapeShellArg( $wgDBserver ) .

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r54410Add fixme note to replace 'mysql' command-line callout with proper usage of a...brion23:24, 4 August 2009

Status & tagging log