Skip to content

Commit

Permalink
Flush logs only in log write thread
Browse files Browse the repository at this point in the history
  • Loading branch information
ch1bo committed Mar 17, 2023
1 parent bbe90bf commit 5f7efd9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hydra-node/src/Hydra/Logging.hs
Expand Up @@ -105,7 +105,7 @@ withTracerOutputTo ::
withTracerOutputTo hdl namespace action = do
msgQueue <- newTBQueueIO @_ @(Envelope msg) defaultQueueSize
withAsync (writeLogs msgQueue `finally` flushLogs msgQueue) $ \_ ->
action (tracer msgQueue) `finally` flushLogs msgQueue
action (tracer msgQueue)
where
tracer queue =
Tracer $
Expand Down

0 comments on commit 5f7efd9

Please sign in to comment.