@@ -210,14 +210,14 @@ getSMPAgentClient_ clientId cfg initServers store backgroundMode =
210
210
runAgentThreads c
211
211
| backgroundMode = run c " subscriber" $ subscriber c
212
212
| otherwise = do
213
- restoreServersStats c
213
+ -- restoreServersStats c
214
214
raceAny_
215
215
[ run c " subscriber" $ subscriber c,
216
216
run c " runNtfSupervisor" $ runNtfSupervisor c,
217
- run c " cleanupManager" $ cleanupManager c,
218
- run c " logServersStats" $ logServersStats c
217
+ run c " cleanupManager" $ cleanupManager c
218
+ -- run c "logServersStats" $ logServersStats c
219
219
]
220
- `E.finally` saveServersStats c
220
+ -- `E.finally` saveServersStats c
221
221
run AgentClient {subQ, acThread} name a =
222
222
a `E.catchAny` \ e -> whenM (isJust <$> readTVarIO acThread) $ do
223
223
logError $ " Agent thread " <> name <> " crashed: " <> tshow e
@@ -234,12 +234,13 @@ logServersStats c = do
234
234
235
235
saveServersStats :: AgentClient -> AM' ()
236
236
saveServersStats c@ AgentClient {subQ, smpServersStats, xftpServersStats} = do
237
- sss <- mapM (lift . getAgentSMPServerStats) =<< readTVarIO smpServersStats
238
- xss <- mapM (lift . getAgentXFTPServerStats) =<< readTVarIO xftpServersStats
239
- let stats = AgentPersistedServerStats {smpServersStats = sss, xftpServersStats = xss}
240
- tryAgentError' (withStore' c (`updateServersStats` stats)) >>= \ case
241
- Left e -> atomically $ writeTBQueue subQ (" " , " " , AEvt SAEConn $ ERR $ INTERNAL $ show e)
242
- Right () -> pure ()
237
+ -- sss <- mapM (lift . getAgentSMPServerStats) =<< readTVarIO smpServersStats
238
+ -- xss <- mapM (lift . getAgentXFTPServerStats) =<< readTVarIO xftpServersStats
239
+ -- let stats = AgentPersistedServerStats {smpServersStats = sss, xftpServersStats = xss}
240
+ -- tryAgentError' (withStore' c (`updateServersStats` stats)) >>= \case
241
+ -- Left e -> atomically $ writeTBQueue subQ ("", "", AEvt SAEConn $ ERR $ INTERNAL $ show e)
242
+ -- Right () -> pure ()
243
+ pure ()
243
244
244
245
restoreServersStats :: AgentClient -> AM' ()
245
246
restoreServersStats c@ AgentClient {smpServersStats, xftpServersStats, srvStatsStartedAt} = do
0 commit comments