ganeti-htoolsSource codeContentsIndex
Ganeti.HTools.Program.Hbal
Description
Cluster rebalancer.
Synopsis
options :: [OptType]
iterateDepth :: Table -> Int -> Bool -> Bool -> Int -> Int -> [MoveJob] -> Bool -> Score -> Score -> Score -> Bool -> IO (Table, [MoveJob])
formatOneline :: Double -> Int -> Double -> String
waitForJobs :: Client -> [String] -> IO (Result [JobStatus])
checkJobsStatus :: [JobStatus] -> Bool
execWrapper :: String -> List -> List -> IORef Int -> [JobSet] -> IO Bool
execJobSet :: String -> List -> List -> IORef Int -> [JobSet] -> IO Bool
hangleSigInt :: IORef Int -> IO ()
hangleSigTerm :: IORef Int -> IO ()
runJobSet :: String -> List -> List -> [JobSet] -> IO Bool
main :: IO ()
Documentation
options :: [OptType]Source
Options list and functions.
iterateDepthSource
:: TableThe starting table
-> IntRemaining length
-> BoolAllow disk moves
-> BoolAllow instance moves
-> IntMax node name len
-> IntMax instance name len
-> [MoveJob]Current command list
-> BoolWhether to be silent
-> ScoreScore at which to stop
-> ScoreMin gain limit
-> ScoreMin score gain
-> BoolEnable evacuation mode
-> IO (Table, [MoveJob])The resulting table and commands
Start computing the solution at the given depth and recurse until we find a valid solution or we exceed the maximum depth.
formatOneline :: Double -> Int -> Double -> StringSource
Formats the solution for the oneline display.
waitForJobs :: Client -> [String] -> IO (Result [JobStatus])Source
Polls a set of jobs at a fixed interval until all are finished one way or another.
checkJobsStatus :: [JobStatus] -> BoolSource
Check that a set of job statuses is all success.
execWrapper :: String -> List -> List -> IORef Int -> [JobSet] -> IO BoolSource
Wrapper over execJobSet checking for early termination.
execJobSet :: String -> List -> List -> IORef Int -> [JobSet] -> IO BoolSource
Execute an entire jobset.
hangleSigInt :: IORef Int -> IO ()Source
Signal handler for graceful termination.
hangleSigTerm :: IORef Int -> IO ()Source
Signal handler for immediate termination.
runJobSet :: String -> List -> List -> [JobSet] -> IO BoolSource
Runs a job set with handling of signals.
main :: IO ()Source
Main function.
Produced by Haddock version 2.6.0