MediaWiki  1.23.0
RedisConnRef Class Reference

Helper class to handle automatically marking connectons as reusable (via RAII pattern) More...

Collaboration diagram for RedisConnRef:

Public Member Functions

 __call ( $name, $arguments)
 
 __construct (RedisConnectionPool $pool, $server, Redis $conn)
 
 __destruct ()
 
 clearLastError ()
 
 getLastError ()
 
 getServer ()
 
 isConnIdentical (Redis $conn)
 
 luaEval ( $script, array $params, $numKeys)
 

Protected Attributes

Redis $conn
 
 $lastError
 
RedisConnectionPool $pool
 
 $server
 

Detailed Description

Helper class to handle automatically marking connectons as reusable (via RAII pattern)

This class simply wraps the Redis class and can be used the same way

Since
1.21

Definition at line 348 of file RedisConnectionPool.php.

Constructor & Destructor Documentation

◆ __construct()

RedisConnRef::__construct ( RedisConnectionPool  $pool,
  $server,
Redis  $conn 
)
Parameters
RedisConnectionPool$pool
string$server
Redis$conn

Definition at line 360 of file RedisConnectionPool.php.

References $conn, $pool, $server, and server.

◆ __destruct()

RedisConnRef::__destruct ( )

Definition at line 448 of file RedisConnectionPool.php.

References server.

Member Function Documentation

◆ __call()

RedisConnRef::__call (   $name,
  $arguments 
)

Definition at line 382 of file RedisConnectionPool.php.

References $conn, $lastError, $name, $res, array(), server, and wfDebugLog().

◆ clearLastError()

RedisConnRef::clearLastError ( )

Definition at line 378 of file RedisConnectionPool.php.

◆ getLastError()

RedisConnRef::getLastError ( )

Definition at line 374 of file RedisConnectionPool.php.

References $lastError.

◆ getServer()

RedisConnRef::getServer ( )
Returns
string
Since
1.23

Definition at line 370 of file RedisConnectionPool.php.

References $server.

Referenced by RedisConnectionPool\handleError().

◆ isConnIdentical()

RedisConnRef::isConnIdentical ( Redis  $conn)
Parameters
Redis$conn
Returns
bool

Definition at line 444 of file RedisConnectionPool.php.

References $conn.

Referenced by RedisConnectionPool\handleError().

◆ luaEval()

RedisConnRef::luaEval (   $script,
array  $params,
  $numKeys 
)

Member Data Documentation

◆ $conn

Redis RedisConnRef::$conn
protected

Definition at line 350 of file RedisConnectionPool.php.

Referenced by __call(), __construct(), isConnIdentical(), and luaEval().

◆ $lastError

RedisConnRef::$lastError
protected

Definition at line 353 of file RedisConnectionPool.php.

Referenced by __call(), getLastError(), and luaEval().

◆ $pool

RedisConnectionPool RedisConnRef::$pool
protected

Definition at line 349 of file RedisConnectionPool.php.

Referenced by __construct().

◆ $server

RedisConnRef::$server
protected

Definition at line 352 of file RedisConnectionPool.php.

Referenced by __construct(), getServer(), and luaEval().


The documentation for this class was generated from the following file: