From 62ced62aac8b3f5f8e22e19d31022313f8340b2f Mon Sep 17 00:00:00 2001 From: lafirest Date: Mon, 21 Feb 2022 14:33:36 +0800 Subject: [PATCH] fix(emqx_mgmt_http): add slow subs api into emqx_mgmt_http api list --- apps/emqx_management/src/emqx_mgmt_http.erl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/emqx_management/src/emqx_mgmt_http.erl b/apps/emqx_management/src/emqx_mgmt_http.erl index 8e92b7371..010a4fce2 100644 --- a/apps/emqx_management/src/emqx_mgmt_http.erl +++ b/apps/emqx_management/src/emqx_mgmt_http.erl @@ -89,7 +89,8 @@ listener_name(Proto) -> http_handlers() -> Plugins = lists:map(fun(Plugin) -> Plugin#plugin.name end, emqx_plugins:list()), - [{"/api/v4", minirest:handler(#{apps => Plugins ++ [emqx_modules] -- ?EXCEPT_PLUGIN, + [{"/api/v4", minirest:handler(#{apps => Plugins ++ + [emqx_plugin_libs, emqx_modules] -- ?EXCEPT_PLUGIN, except => ?EXCEPT, filter => fun ?MODULE:filter/1}), [{authorization, fun ?MODULE:authorize_appid/1}]}]. @@ -128,6 +129,7 @@ filter(_) -> true. -else. filter(#{app := emqx_modules}) -> true; +filter(#{app := emqx_plugin_libs}) -> true; filter(#{app := App}) -> case emqx_plugins:find_plugin(App) of false -> false;