diff options
author | 2012-09-06 14:56:04 -0400 | |
---|---|---|
committer | 2012-09-06 14:56:04 -0400 | |
commit | a00f1d26bc3f121e49ee3f6ff5f46d7b330161ff (patch) | |
tree | 1951e9ca7e482fc67f9c232b0fb22680ee19f5a0 /Assistant/DaemonStatus.hs | |
parent | d11ded822cf68d4f33a886e0f97f95a3781e0dc1 (diff) |
display errors when any named thread crashes
Diffstat (limited to 'Assistant/DaemonStatus.hs')
-rw-r--r-- | Assistant/DaemonStatus.hs | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/Assistant/DaemonStatus.hs b/Assistant/DaemonStatus.hs index b5dd08d0e..c6942530c 100644 --- a/Assistant/DaemonStatus.hs +++ b/Assistant/DaemonStatus.hs @@ -8,9 +8,7 @@ module Assistant.DaemonStatus where import Common.Annex -import Assistant.ThreadedMonad import Assistant.Alert -import Utility.ThreadScheduler import Utility.TempFile import Utility.NotificationBroadcaster import Logs.Transfer @@ -114,23 +112,6 @@ startDaemonStatus = do , knownRemotes = remotes } -{- This writes the daemon status to disk, when it changes, but no more - - frequently than once every ten minutes. - -} -daemonStatusThread :: ThreadState -> DaemonStatusHandle -> IO () -daemonStatusThread st dstatus = do - notifier <- newNotificationHandle - =<< changeNotifier <$> getDaemonStatus dstatus - checkpoint - runEvery (Seconds tenMinutes) $ do - waitNotification notifier - checkpoint - where - checkpoint = do - status <- getDaemonStatus dstatus - file <- runThreadState st $ fromRepo gitAnnexDaemonStatusFile - writeDaemonStatusFile file status - {- Don't just dump out the structure, because it will change over time, - and parts of it are not relevant. -} writeDaemonStatusFile :: FilePath -> DaemonStatus -> IO () |