Browse Source

Merge pull request #366 from getong/fix_ranch_error_log_three_parameters

log the ranch error msg
pull/302/merge
Mark Allen 8 years ago
committed by GitHub
parent
commit
3590d49f9f
1 changed files with 6 additions and 1 deletions
  1. +6
    -1
      src/error_logger_lager_h.erl

+ 6
- 1
src/error_logger_lager_h.erl View File

@ -189,7 +189,12 @@ log_event(Event, #state{sink=Sink} = State) ->
[Ref, _Protocol, Worker, Reason] ->
?LOGFMT(Sink, error, Worker,
"Ranch listener ~p terminated with reason: ~s",
[Ref, format_reason(Reason)])
[Ref, format_reason(Reason)]);
[Ref, Protocol, Ret] ->
%% ranch_conns_sup.erl module line 119-123 has three parameters error msg, log it.
?LOGFMT(Sink, error, Protocol,
"Ranch listener ~p terminated with result:~s",
[Ref, format_reason(Ret)])
end;
{false, "webmachine error"++_} ->
%% Webmachine HTTP server error

Loading…
Cancel
Save