MediaWiki  REL1_24
MySqlLockManager Class Reference

MySQL version of DBLockManager that supports shared locks. More...

Inheritance diagram for MySqlLockManager:
Collaboration diagram for MySqlLockManager:

List of all members.

Protected Member Functions

 doGetLocksOnServer ($lockSrv, array $paths, $type)
 Get a connection to a lock DB and acquire locks on $paths.
 initConnection ($lockDb, DatabaseBase $db)
 releaseAllLocks ()

Protected Attributes

array $lockTypeMap
 Mapping of lock types to the type actually used *.

Detailed Description

MySQL version of DBLockManager that supports shared locks.

All locks are non-blocking, which avoids deadlocks.

Definition at line 244 of file DBLockManager.php.


Member Function Documentation

MySqlLockManager::doGetLocksOnServer ( lockSrv,
array paths,
type 
) [protected]

Get a connection to a lock DB and acquire locks on $paths.

This does not use GET_LOCK() per http://bugs.mysql.com/bug.php?id=1118.

See also:
DBLockManager::getLocksOnServer()
Parameters:
string$lockSrv
array$paths
string$type
Returns:
Status

Definition at line 270 of file DBLockManager.php.

MySqlLockManager::initConnection ( lockDb,
DatabaseBase db 
) [protected]
Parameters:
string$lockDb
DatabaseBase$db

Reimplemented from DBLockManager.

Definition at line 255 of file DBLockManager.php.

See also:
QuorumLockManager::releaseAllLocks()
Returns:
Status

Reimplemented from QuorumLockManager.

Definition at line 340 of file DBLockManager.php.


Member Data Documentation

array MySqlLockManager::$lockTypeMap [protected]
Initial value:
 array(
        self::LOCK_SH => self::LOCK_SH,
        self::LOCK_UW => self::LOCK_SH,
        self::LOCK_EX => self::LOCK_EX
    )

Mapping of lock types to the type actually used *.

Reimplemented from LockManager.

Definition at line 245 of file DBLockManager.php.


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