Compare commits

...
2 changed files with 9 additions and 8 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
cabal-version: 1.12 cabal-version: 1.12
name: simplexmq name: simplexmq
version: 6.2.1.0 version: 6.2.1.100
synopsis: SimpleXMQ message broker synopsis: SimpleXMQ message broker
description: This package includes <./docs/Simplex-Messaging-Server.html server>, description: This package includes <./docs/Simplex-Messaging-Server.html server>,
<./docs/Simplex-Messaging-Client.html client> and <./docs/Simplex-Messaging-Client.html client> and
+8 -7
View File
@@ -221,13 +221,14 @@ getSMPAgentClient_ clientId cfg initServers@InitialAgentServers {smp, xftp} stor
| backgroundMode = run c "subscriber" $ subscriber c | backgroundMode = run c "subscriber" $ subscriber c
| otherwise = do | otherwise = do
restoreServersStats c restoreServersStats c
raceAny_ run c "subscriber" $ subscriber c
[ run c "subscriber" $ subscriber c, -- raceAny_
run c "runNtfSupervisor" $ runNtfSupervisor c, -- [ run c "subscriber" $ subscriber c
run c "cleanupManager" $ cleanupManager c, -- run c "runNtfSupervisor" $ runNtfSupervisor c,
run c "logServersStats" $ logServersStats c -- run c "cleanupManager" $ cleanupManager c,
] -- run c "logServersStats" $ logServersStats c
`E.finally` saveServersStats c -- ]
-- `E.finally` saveServersStats c
run AgentClient {subQ, acThread} name a = run AgentClient {subQ, acThread} name a =
a `E.catchAny` \e -> whenM (isJust <$> readTVarIO acThread) $ do a `E.catchAny` \e -> whenM (isJust <$> readTVarIO acThread) $ do
logError $ "Agent thread " <> name <> " crashed: " <> tshow e logError $ "Agent thread " <> name <> " crashed: " <> tshow e