r54983 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r54982‎ | r54983 | r54984 >
Date:22:57, 13 August 2009
Author:brion
Status:deferred
Tags:
Comment:
log when we're failing/timing out (fixme: this kinda sucks anyway)
Modified paths:
  • /trunk/extensions/LocalisationUpdate/LocalisationUpdate.class.php (modified) (history)

Diff [purge]

Index: trunk/extensions/LocalisationUpdate/LocalisationUpdate.class.php
@@ -141,8 +141,11 @@
142142 // use cURL to get the SVN contents
143143 if ( preg_match( "/^http/", $basefile ) ) {
144144 while( !$basefilecontents && $attempts <= $wgLocalisationUpdateRetryAttempts) {
145 - if($attempts > 0)
146 - sleep(1);
 145+ if($attempts > 0) {
 146+ $delay = 1;
 147+ self::myLog( "Failed to download " . $basefile . "; retrying in ${delay}s..." );
 148+ sleep( $delay );
 149+ }
147150 $basefilecontents = Http::get( $basefile );
148151 $attempts++;
149152 }

Status & tagging log