Merge pull request #6816 from EMQ-YangM/moreReason

fix(emqx_plugin_libs_pool): throw error with Reason
This commit is contained in:
Yang Miao 2022-01-26 10:42:49 +08:00 committed by GitHub
commit 2ea4c1c7ef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -37,7 +37,7 @@ start_pool(Name, Mod, Options) ->
{error, Reason} ->
?SLOG(error, #{msg => "start_ecpool_error", pool_name => Name,
reason => Reason}),
error({start_pool_failed, Name})
error({start_pool_failed, Name, Reason})
end.
stop_pool(Name) ->
@ -49,7 +49,7 @@ stop_pool(Name) ->
{error, Reason} ->
?SLOG(error, #{msg => "stop_ecpool_failed", pool_name => Name,
reason => Reason}),
error({stop_pool_failed, Name})
error({stop_pool_failed, Name, Reason})
end.
health_check(PoolName, CheckFunc, State) when is_function(CheckFunc) ->