Commit 6c3995d5 authored by Klaus Aehlig's avatar Klaus Aehlig

Make maintd avoid no-op config changes

While changes with no net effect wouldn't hurt any correctness
properties, still the modification time and serial of the maintenance
entry in the configuration would be changed and the configuration
distributed to all master candidates. These unexpected configuration
changes can be confusing; they definitely do confuse some QA tests.
Signed-off-by: default avatarKlaus Aehlig <>
Reviewed-by: default avatarHelga Velroyen <>
parent 9e97280e
......@@ -127,14 +127,16 @@ maintenance memstate = do
. tryIOError $ L.getLuxiClient luxiSocket)
(liftIO . L.closeClient)
$ void . mkResultT . waitForJobs oldjobs
liftIO $ clearJobs memstate
unless (null oldjobs)
. liftIO $ clearJobs memstate
logDebug "New round of maintenance started"
cData <- loadClusterData
let il = cdInstances cData
nl = cdNodes cData
nidxs = Set.fromList $ Container.keys nl
(nidxs', jobs) <- harepTasks (nl, il) nidxs
liftIO $ appendJobs memstate jobs
unless (null oldjobs)
. liftIO $ appendJobs memstate jobs
logDebug $ "Unaffected nodes " ++ show (Set.toList nidxs')
++ ", jobs submitted " ++ show (map fromJobId jobs)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment