"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "includes/libs/lockmanager/RedisLockManager.php" between
mediawiki-1.31.1.tar.gz and mediawiki-1.32.0.tar.gz

About: MediaWiki is a wiki engine (the collaborative editing software that runs for e.g. Wikipedia, the free encyclopedia).

RedisLockManager.php  (mediawiki-1.31.1):RedisLockManager.php  (mediawiki-1.32.0)
skipping to change at line 79 skipping to change at line 79
$this->srvsByBucket = array_filter( $config['srvsByBucket'], 'is_ array' ); $this->srvsByBucket = array_filter( $config['srvsByBucket'], 'is_ array' );
$this->srvsByBucket = array_values( $this->srvsByBucket ); // con secutive $this->srvsByBucket = array_values( $this->srvsByBucket ); // con secutive
$config['redisConfig']['serializer'] = 'none'; $config['redisConfig']['serializer'] = 'none';
$this->redisPool = RedisConnectionPool::singleton( $config['redis Config'] ); $this->redisPool = RedisConnectionPool::singleton( $config['redis Config'] );
} }
protected function getLocksOnServer( $lockSrv, array $pathsByType ) { protected function getLocksOnServer( $lockSrv, array $pathsByType ) {
$status = StatusValue::newGood(); $status = StatusValue::newGood();
$pathList = call_user_func_array( 'array_merge', array_values( $p athsByType ) ); $pathList = array_merge( ...array_values( $pathsByType ) );
$server = $this->lockServers[$lockSrv]; $server = $this->lockServers[$lockSrv];
$conn = $this->redisPool->getConnection( $server, $this->logger ) ; $conn = $this->redisPool->getConnection( $server, $this->logger ) ;
if ( !$conn ) { if ( !$conn ) {
foreach ( $pathList as $path ) { foreach ( $pathList as $path ) {
$status->fatal( 'lockmanager-fail-acquirelock', $ path ); $status->fatal( 'lockmanager-fail-acquirelock', $ path );
} }
return $status; return $status;
} }
skipping to change at line 174 skipping to change at line 174
$status->fatal( 'lockmanager-fail-acquirelock', $ pathsByKey[$key] ); $status->fatal( 'lockmanager-fail-acquirelock', $ pathsByKey[$key] );
} }
} }
return $status; return $status;
} }
protected function freeLocksOnServer( $lockSrv, array $pathsByType ) { protected function freeLocksOnServer( $lockSrv, array $pathsByType ) {
$status = StatusValue::newGood(); $status = StatusValue::newGood();
$pathList = call_user_func_array( 'array_merge', array_values( $p athsByType ) ); $pathList = array_merge( ...array_values( $pathsByType ) );
$server = $this->lockServers[$lockSrv]; $server = $this->lockServers[$lockSrv];
$conn = $this->redisPool->getConnection( $server, $this->logger ) ; $conn = $this->redisPool->getConnection( $server, $this->logger ) ;
if ( !$conn ) { if ( !$conn ) {
foreach ( $pathList as $path ) { foreach ( $pathList as $path ) {
$status->fatal( 'lockmanager-fail-releaselock', $ path ); $status->fatal( 'lockmanager-fail-releaselock', $ path );
} }
return $status; return $status;
} }
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)