r94252 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r94251‎ | r94252 | r94253 >
Date:15:29, 11 August 2011
Author:demon
Status:ok
Tags:
Comment:
Wrap site_stats update in a begin()/commit() to see if this helps
* For trunk: need rewriting to use $dbw->update()
* More generally: manual site_stats updates suck, we should fix this
Modified paths:
  • /branches/wmf/1.17wmf1/includes/filerepo/LocalFile.php (modified) (history)

Diff [purge]

Index: branches/wmf/1.17wmf1/includes/filerepo/LocalFile.php
@@ -963,8 +963,10 @@
964964 } else {
965965 # This is a new file
966966 # Update the image count
 967+ $dbw->begin();
967968 $site_stats = $dbw->tableName( 'site_stats' );
968969 $dbw->query( "UPDATE $site_stats SET ss_images=ss_images+1", __METHOD__ );
 970+ $dbw->commit();
969971 }
970972
971973 $descTitle = $this->getTitle();

Follow-up revisions

RevisionCommit summaryAuthorDate
r94450Forport from 1.17wmf1 to 1.18...hashar10:33, 14 August 2011
r95446Merge r94252 to trunk...reedy21:31, 24 August 2011

Status & tagging log