浏览代码

Merge pull request #366 from getong/fix_ranch_error_log_three_parameters

log the ranch error msg
pull/302/merge
Mark Allen 8 年前
提交者 GitHub
父节点
当前提交
3590d49f9f
共有 1 个文件被更改,包括 6 次插入1 次删除
  1. +6
    -1
      src/error_logger_lager_h.erl

+ 6
- 1
src/error_logger_lager_h.erl 查看文件

@ -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

正在加载...
取消
保存