Shell: continue better logging
This commit is contained in:
parent
5915e98a55
commit
b5515ea99e
@ -491,7 +491,9 @@ module Make
|
|||||||
| Ok () ->
|
| Ok () ->
|
||||||
loop ()
|
loop ()
|
||||||
| Error [Canceled | Exn Lwt_pipe.Closed | Exn Lwt_dropbox.Closed ] ->
|
| Error [Canceled | Exn Lwt_pipe.Closed | Exn Lwt_dropbox.Closed ] ->
|
||||||
Logger.lwt_log_notice "@[Worker terminated [%a] @]" Name.pp w.name >>= fun () ->
|
Logger.lwt_log_notice
|
||||||
|
"@[Worker terminated [%a] @]"
|
||||||
|
Name.pp w.name >>= fun () ->
|
||||||
do_close None
|
do_close None
|
||||||
| Error errs ->
|
| Error errs ->
|
||||||
begin match w.current_request with
|
begin match w.current_request with
|
||||||
@ -505,11 +507,14 @@ module Make
|
|||||||
| Ok () ->
|
| Ok () ->
|
||||||
loop ()
|
loop ()
|
||||||
| Error ([Timeout] as errs) ->
|
| Error ([Timeout] as errs) ->
|
||||||
Logger.lwt_log_notice "Worker terminated with timeout" >>= fun () ->
|
Logger.lwt_log_notice
|
||||||
|
"@[Worker terminated with timeout [%a] @]"
|
||||||
|
Name.pp w.name >>= fun () ->
|
||||||
do_close (Some errs)
|
do_close (Some errs)
|
||||||
| Error errs ->
|
| Error errs ->
|
||||||
Logger.lwt_log_error
|
Logger.lwt_log_error
|
||||||
"@[<v 0>Worker crashed:@,%a@]"
|
"@[<v 0>Worker crashed [%a]:@,%a@]"
|
||||||
|
Name.pp w.name
|
||||||
(Format.pp_print_list Error_monad.pp) errs >>= fun () ->
|
(Format.pp_print_list Error_monad.pp) errs >>= fun () ->
|
||||||
do_close (Some errs) in
|
do_close (Some errs) in
|
||||||
loop ()
|
loop ()
|
||||||
|
Loading…
Reference in New Issue
Block a user