Reduce logging further

This commit is contained in:
Manuel 2021-06-05 23:34:12 +02:00
parent 6c153d6bf1
commit 459c2dd158
Signed by: SunRed
GPG Key ID: 4085037435E1F07A
1 changed files with 4 additions and 4 deletions

View File

@ -83,9 +83,9 @@ startCleanup = do
timer t = forever $ do
-- Takes time in microseconds
threadDelay $ t * 60000000
logInfo ["Starting cleanup of containers"]
logDebug ["Starting cleanup of containers"]
n <- killContainers
logInfo ["Cleaned up ", cs $ show n, " containers, next in ", cs $ show t, " minutes"]
logDebug ["Cleaned up ", cs $ show n, " containers, next in ", cs $ show t, " minutes"]
timer t
setupContainer :: Language -> Myriad ContainerName
@ -152,9 +152,9 @@ killContainer lang = do
killContainers :: Myriad [ContainerName]
killContainers = do
containers <- gview #containers >>= readMVar
logInfo ["Starting killing of containers"]
logDebug ["Starting killing of containers"]
xs <- forConcurrently (M.toList containers) $ \(k, v) -> (v,) <$> killContainer k
logInfo ["Finished killing of containers"]
logDebug ["Finished killing of containers"]
pure . map fst $ filter snd xs
evalCode :: Language -> Int -> String -> Myriad EvalResult