Merge pull request #12820 from SergeTupchiy/EMQX-12124-fix-msgs-api-client-shutdown-followup-fix
fix(emqx_mgmt): do not attempt to get a stacktrace of a remote process
This commit is contained in:
commit
ed97a7c08e
|
@ -715,15 +715,20 @@ call_conn(ConnMod, Pid, Req) ->
|
||||||
exit:{{shutdown, _OOMInfo}, _Location} ->
|
exit:{{shutdown, _OOMInfo}, _Location} ->
|
||||||
{error, shutdown};
|
{error, shutdown};
|
||||||
exit:timeout ->
|
exit:timeout ->
|
||||||
?SLOG(
|
LogData = #{
|
||||||
warning,
|
|
||||||
#{
|
|
||||||
msg => "call_client_connection_process_timeout",
|
msg => "call_client_connection_process_timeout",
|
||||||
request => Req,
|
request => Req,
|
||||||
pid => Pid,
|
pid => Pid,
|
||||||
module => ConnMod,
|
module => ConnMod
|
||||||
stacktrace => erlang:process_info(Pid, current_stacktrace)
|
},
|
||||||
}
|
LogData1 =
|
||||||
),
|
case node(Pid) =:= node() of
|
||||||
|
true ->
|
||||||
|
LogData#{stacktrace => erlang:process_info(Pid, current_stacktrace)};
|
||||||
|
false ->
|
||||||
|
LogData
|
||||||
|
end,
|
||||||
|
|
||||||
|
?SLOG(warning, LogData1),
|
||||||
{error, timeout}
|
{error, timeout}
|
||||||
end.
|
end.
|
||||||
|
|
Loading…
Reference in New Issue