From: River Tarnell Date: Fri, 11 May 2007 07:49:32 +0000 (+0000) Subject: fixes X-Git-Tag: 1.31.0-rc.0~52952 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/operations/?a=commitdiff_plain;h=422f6fa21ba330ccb3728cdbbf290f7bed6e1bde;p=lhc%2Fweb%2Fwiklou.git fixes --- diff --git a/maintenance/nextJobDB.php b/maintenance/nextJobDB.php index 3073227ebb..ffc8b4ba8c 100644 --- a/maintenance/nextJobDB.php +++ b/maintenance/nextJobDB.php @@ -12,7 +12,11 @@ $type = isset($options['type']) ? $options['type'] : false; -$pendingDBs = $wgMemc->get( 'jobqueue:dbs' ); +$mckey = $type === false + ? "jobqueue:dbs" + : "jobqueue:dbs:$type"; + +$pendingDBs = $wgMemc->get( $mckey ); if ( !$pendingDBs ) { $pendingDBs = array(); # Cross-reference DBs by master DB server @@ -39,7 +43,7 @@ if ( !$pendingDBs ) { if ($type === false) $sql .= "(SELECT '$dbName' FROM `$dbName`.job LIMIT 1)"; else - $sql .= "(SELECT '$dbName' FROM `$dbName`.job WHERE job_cmd='$stype' LIMIT 1)"; + $sql .= "(SELECT '$dbName' FROM `$dbName`.job WHERE job_cmd=$stype LIMIT 1)"; } $res = $dbConn->query( $sql, 'nextJobDB.php' ); $row = $dbConn->fetchRow( $res ); // discard padding row @@ -48,7 +52,7 @@ if ( !$pendingDBs ) { } } - $wgMemc->set( 'jobqueue:dbs', $pendingDBs, 300 ); + $wgMemc->set( $mckey, $pendingDBs, 300 ); } if ( $pendingDBs ) {