r99928 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r99927‎ | r99928 | r99929 >
Date:23:10, 15 October 2011
Author:reedy
Status:ok (Comments)
Tags:
Comment:
Commit maintenance scripts
Modified paths:
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/fixBug28348.inc (modified) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-alswiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-arwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-bewiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-bnwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-bswiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-de_labswikimedia (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-dewiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-dewikiquote (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-dewiktionary (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-en_labswikimedia (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-enwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-enwikibooks (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-enwikinews (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-eowiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-eswikinews (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-fawikinews (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-flaggedrevs_labswikimedia (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-frwikinews (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-hewikisource (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-hiwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-huwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-iawiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-idwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-iswiktionary (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-kawiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-mediawikiwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-mkwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-plwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-plwikisource (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-plwiktionary (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ptwikinews (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ptwikisource (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ruwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ruwikiquote (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ruwikisource (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-sqwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-srwikinews (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-tawikinews (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-test2wiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-testwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-trwiki (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ukwiktionary (added) (history)
  • /branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-zh_classicalwiki (added) (history)

Diff [purge]

Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ukwiktionary
@@ -0,0 +1 @@
 2+144859
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-hewikisource
@@ -0,0 +1 @@
 2+426099
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ptwikinews
@@ -0,0 +1 @@
 2+147258
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-dewiktionary
@@ -0,0 +1 @@
 2+1988680
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-bewiki
@@ -0,0 +1 @@
 2+909467
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-enwikinews
@@ -0,0 +1 @@
 2+1302328
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-bnwiki
@@ -0,0 +1 @@
 2+1019752
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-en_labswikimedia
@@ -0,0 +1 @@
 2+89048
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-eswikinews
@@ -0,0 +1 @@
 2+232834
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-bswiki
@@ -0,0 +1 @@
 2+1568584
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-testwiki
@@ -0,0 +1 @@
 2+120092
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-alswiki
@@ -0,0 +1 @@
 2+369653
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-fawikinews
@@ -0,0 +1 @@
 2+93281
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ruwiki
@@ -0,0 +1 @@
 2+38428058
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-kawiki
@@ -0,0 +1 @@
 2+1709513
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-zh_classicalwiki
@@ -0,0 +1 @@
 2+191169
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-frwikinews
@@ -0,0 +1 @@
 2+369168
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-sqwiki
@@ -0,0 +1 @@
 2+1026237
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-dewiki
@@ -0,0 +1 @@
 2+94754152
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-flaggedrevs_labswikimedia
@@ -0,0 +1 @@
 2+17984
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-plwikisource
@@ -0,0 +1 @@
 2+287774
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-hiwiki
@@ -0,0 +1 @@
 2+1533141
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-enwikibooks
@@ -0,0 +1 @@
 2+2181416
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/fixBug28348.inc
@@ -3,8 +3,14 @@
44 function update_images_bug_28348( $start = null ) {
55 echo "Correcting fi_img_timestamp column in flaggedimages\n";
66
7 - $BATCH_SIZE = 1000;
 7+ $BATCH_SIZE = 5000;
88
 9+ $logFilePath = "bug28348-fixed-" . wfWikiID();
 10+ if ( 0 && file_exists( $logFilePath ) ) {
 11+ echo "Already done\n";
 12+ return;
 13+ }
 14+
915 $db = wfGetDB( DB_MASTER );
1016
1117 if( $start === null ) {
@@ -63,15 +69,18 @@
6470 }
6571 }
6672 }
 73+ $didAnything = ( $res->numRows() > 0 );
 74+ file_put_contents( $logFilePath, $logDump, FILE_APPEND );
 75+ $logDump = '';
6776 $db->commit();
6877
6978 $db->freeResult( $res );
7079 $blockStart += $BATCH_SIZE;
7180 $blockEnd += $BATCH_SIZE;
72 - wfWaitForSlaves( 5 );
 81+ if ( $didAnything ) {
 82+ wfWaitForSlaves( 5 );
 83+ }
7384 }
7485
75 - file_put_contents( "bug28348-fixed-" . wfWikiID(), $logDump );
76 -
7786 echo "fi_img_timestamp column fixes complete ... {$count} rows [{$changed} changed]\n";
7887 }
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-mediawikiwiki
@@ -0,0 +1 @@
 2+444611
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ptwikisource
@@ -0,0 +1 @@
 2+233158
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-dewikiquote
@@ -0,0 +1 @@
 2+455810
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ruwikisource
@@ -0,0 +1 @@
 2+625527
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-plwiktionary
@@ -0,0 +1 @@
 2+2400028
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-plwiki
@@ -0,0 +1 @@
 2+28323168
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-huwiki
@@ -0,0 +1 @@
 2+10519119
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-srwikinews
@@ -0,0 +1 @@
 2+3093072
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-trwiki
@@ -0,0 +1 @@
 2+10192741
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-iawiki
@@ -0,0 +1 @@
 2+350966
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-de_labswikimedia
@@ -0,0 +1 @@
 2+29409
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-idwiki
@@ -0,0 +1 @@
 2+4832062
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-tawikinews
@@ -0,0 +1 @@
 2+20270
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-test2wiki
@@ -0,0 +1 @@
 2+36226
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-enwiki
@@ -0,0 +1 @@
 2+454526466
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-arwiki
@@ -0,0 +1 @@
 2+7607775
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-eowiki
@@ -0,0 +1 @@
 2+3885964
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-ruwikiquote
@@ -0,0 +1 @@
 2+140683
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-mkwiki
@@ -0,0 +1 @@
 2+2121340
\ No newline at end of file
Index: branches/wmf/1.18wmf1/extensions/FlaggedRevs/maintenance/popRevTimestampLast-iswiktionary
@@ -0,0 +1 @@
 2+178703
\ No newline at end of file

Follow-up revisions

RevisionCommit summaryAuthorDate
r111194MFT r97505, r97508, r97509, r97512, r99928reedy19:53, 10 February 2012

Comments

#Comment by Tim Starling (talk | contribs)   02:53, 12 December 2011

Tagging reapply for now, but note that you could have a FlaggedRevs/maintenance/wmf directory in trunk, it's not against the law.

Status & tagging log