Revision 3e80d1b7
b/src/Ganeti/WConfd/Monad.hs | ||
---|---|---|
45 | 45 |
, modifyConfigState |
46 | 46 |
, readConfigState |
47 | 47 |
, modifyLockAllocation |
48 |
, readLockAllocation |
|
48 | 49 |
) where |
49 | 50 |
|
50 | 51 |
import Control.Applicative |
... | ... | |
173 | 174 |
in (ds { dsLockAllocation = la' }, r) |
174 | 175 |
atomicModifyIORef (dhDaemonState dh) mf |
175 | 176 |
-- TODO: Trigger the async. lock saving worker |
177 |
|
|
178 |
-- | Read the lock allocation state. |
|
179 |
readLockAllocation :: WConfdMonad GanetiLockAllocation |
|
180 |
readLockAllocation = liftM dsLockAllocation . readIORef . dhDaemonState |
|
181 |
=<< daemonHandle |
Also available in: Unified diff