Trees | Indices | Help |
|
---|
|
The Ganeti Locking Library
The purpose of this small library is to manage locking for ganeti clusters in a central place, while at the same time doing dynamic checks against possible deadlocks. It will also make it easier to transition to a different lock type should we migrate away from python threads.
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|
|||
|
|
|||
_instance = None
|
|
Constructs a new GanetiLockManager object. There should be only a GanetiLockManager object at any time, so this function raises an error if this is not the case.
|
Registers a new lock with the monitor. |
Queries information from all locks. |
List the lock names at the given level. This can be used for debugging/testing purposes.
|
Check if locks at a certain level are owned in a specific mode. See Also: LockSet.check_owned |
Checks whether current thread owns all locks at a certain level. See Also: LockSet.owning_all |
Check if the current thread owns the BGL. Both an exclusive or a shared acquisition work. |
Check if the level contains the BGL. Check if acting on the given level and set of names will change the status of the Big Ganeti Lock. |
Acquire a set of resource locks, at the same level.
|
Downgrade a set of resource locks from exclusive to shared mode. You must have acquired the locks in exclusive mode.
|
Release a set of resource locks, at the same level. You must have acquired the locks, either in shared or in exclusive mode, before releasing them.
|
Add locks at the specified level.
|
Remove locks from the specified level. You must either already own the locks you are trying to remove exclusively or not own any lock at an upper level.
|
Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Fri Jul 4 09:38:49 2014 | http://epydoc.sourceforge.net |