X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=includes%2Flibs%2Frdbms%2FChronologyProtector.php;h=e11528659d4a9334d3fed6466b4b9b7514e05e38;hp=4fcd88599c2a77c0d79f07fe42624e6cb464e831;hb=8269ed4dfd5e4395e25945b1fa2ed391684606ed;hpb=07a791ffd1d80c6a8f2ca4dfdbc3f2002ac869fe diff --git a/includes/libs/rdbms/ChronologyProtector.php b/includes/libs/rdbms/ChronologyProtector.php index 4fcd88599c..e11528659d 100644 --- a/includes/libs/rdbms/ChronologyProtector.php +++ b/includes/libs/rdbms/ChronologyProtector.php @@ -75,7 +75,7 @@ class ChronologyProtector implements LoggerAwareInterface { public function __construct( BagOStuff $store, array $client, $posIndex = null ) { $this->store = $store; $this->clientId = md5( $client['ip'] . "\n" . $client['agent'] ); - $this->key = $store->makeGlobalKey( __CLASS__, $this->clientId, 'v1' ); + $this->key = $store->makeGlobalKey( __CLASS__, $this->clientId, 'v2' ); $this->waitForPosIndex = $posIndex; $this->logger = new NullLogger(); } @@ -124,7 +124,7 @@ class ChronologyProtector implements LoggerAwareInterface { $this->startupPositions[$masterName] instanceof DBMasterPos ) { $pos = $this->startupPositions[$masterName]; - $this->logger->info( __METHOD__ . ": LB for '$masterName' set to pos $pos\n" ); + $this->logger->debug( __METHOD__ . ": LB for '$masterName' set to pos $pos\n" ); $lb->waitFor( $pos ); } } @@ -148,11 +148,11 @@ class ChronologyProtector implements LoggerAwareInterface { if ( $lb->getServerCount() > 1 ) { $pos = $lb->getMasterPos(); if ( $pos ) { - $this->logger->info( __METHOD__ . ": LB for '$masterName' has pos $pos\n" ); + $this->logger->debug( __METHOD__ . ": LB for '$masterName' has pos $pos\n" ); $this->shutdownPositions[$masterName] = $pos; } } else { - $this->logger->info( __METHOD__ . ": DB '$masterName' touched\n" ); + $this->logger->debug( __METHOD__ . ": DB '$masterName' touched\n" ); } $this->shutdownTouchDBs[$masterName] = 1; } @@ -186,7 +186,7 @@ class ChronologyProtector implements LoggerAwareInterface { return []; // nothing to save } - $this->logger->info( __METHOD__ . ": saving master pos for " . + $this->logger->debug( __METHOD__ . ": saving master pos for " . implode( ', ', array_keys( $this->shutdownPositions ) ) . "\n" ); @@ -299,10 +299,10 @@ class ChronologyProtector implements LoggerAwareInterface { } $this->startupPositions = $data ? $data['positions'] : []; - $this->logger->info( __METHOD__ . ": key is {$this->key} (read)\n" ); + $this->logger->debug( __METHOD__ . ": key is {$this->key} (read)\n" ); } else { $this->startupPositions = []; - $this->logger->info( __METHOD__ . ": key is {$this->key} (unread)\n" ); + $this->logger->debug( __METHOD__ . ": key is {$this->key} (unread)\n" ); } }