Merge pull request #7932 from ieQu1/bpapi-sort-versions
fix(bpapi): Sort versions
This commit is contained in:
commit
4c844eba95
2
Makefile
2
Makefile
|
@ -73,7 +73,7 @@ ct: $(REBAR) conf-segs
|
|||
|
||||
.PHONY: static_checks
|
||||
static_checks:
|
||||
@$(REBAR) as check do xref, dialyzer, ct --suite apps/emqx/test/emqx_static_checks --readable $(CT_READABLE)
|
||||
@$(REBAR) as check do dialyzer, xref, ct --suite apps/emqx/test/emqx_static_checks --readable $(CT_READABLE)
|
||||
|
||||
APPS=$(shell $(CURDIR)/scripts/find-apps.sh)
|
||||
|
||||
|
|
|
@ -1,29 +1,28 @@
|
|||
{emqx,1}.
|
||||
{emqx_rule_engine,1}.
|
||||
{emqx_bridge,1}.
|
||||
{emqx_authn,1}.
|
||||
{emqx_authz,1}.
|
||||
{emqx_bridge,1}.
|
||||
{emqx_broker,1}.
|
||||
{emqx_cm,1}.
|
||||
{emqx_conf,1}.
|
||||
{emqx_dashboard,1}.
|
||||
{emqx_delayed,1}.
|
||||
{emqx_exhook,1}.
|
||||
{emqx_gateway_api_listeners,1}.
|
||||
{emqx_gateway_cm,1}.
|
||||
{emqx_gateway_http,1}.
|
||||
{emqx_license,1}.
|
||||
{emqx_management,1}.
|
||||
{emqx_mgmt_api_plugins,1}.
|
||||
{emqx_license,1}.
|
||||
{emqx_mgmt_cluster,1}.
|
||||
{emqx_mgmt_trace,1}.
|
||||
{emqx_persistent_session,1}.
|
||||
{emqx_plugin_libs,1}.
|
||||
{emqx_prometheus,1}.
|
||||
{emqx_resource,1}.
|
||||
{emqx_retainer,1}.
|
||||
{emqx_rule_engine,1}.
|
||||
{emqx_slow_subs,1}.
|
||||
{emqx_statsd,1}.
|
||||
{emqx_telemetry,1}.
|
||||
{emqx_topic_metrics,1}.
|
||||
{emqx_delayed,1}.
|
||||
{emqx_mgmt_cluster,1}.
|
||||
{emqx_retainer,1}.
|
||||
{emqx_gateway_http,1}.
|
||||
{emqx_gateway_api_listeners,1}.
|
||||
|
||||
|
|
|
@ -61,15 +61,13 @@
|
|||
% TODO: handle pmap
|
||||
-define(IGNORED_RPC_CALLS, "gen_rpc:nodes/0, emqx_rpc:unwrap_erpc/1").
|
||||
%% List of business-layer functions that are exempt from the checks:
|
||||
%% erlfmt-ignore
|
||||
-define(EXEMPTIONS,
|
||||
% Reason: legacy code. A fun and a QC query are
|
||||
"emqx_mgmt_api:do_query/6,"
|
||||
% passed in the args, it's futile to try to statically
|
||||
% check it
|
||||
|
||||
% Reason: some sort of external plugin API that we
|
||||
"emqx_plugin_libs_rule:cluster_call/3"
|
||||
% don't want to break?
|
||||
"emqx_mgmt_api:do_query/6," % Reason: legacy code. A fun and a QC query are
|
||||
% passed in the args, it's futile to try to statically
|
||||
% check it
|
||||
"emqx_plugin_libs_rule:cluster_call/3" % Reason: some sort of external plugin API that we
|
||||
% don't want to break?
|
||||
).
|
||||
|
||||
-define(XREF, myxref).
|
||||
|
@ -220,7 +218,7 @@ dump() ->
|
|||
case
|
||||
{
|
||||
filelib:wildcard(project_root_dir() ++ "/*_plt"),
|
||||
filelib:wildcard(project_root_dir() ++ "/_build/emqx*/lib")
|
||||
filelib:wildcard(project_root_dir() ++ "/_build/check/lib")
|
||||
}
|
||||
of
|
||||
{[PLT | _], [RelDir | _]} ->
|
||||
|
@ -260,22 +258,11 @@ prepare(#{reldir := RelDir, plt := PLT}) ->
|
|||
logger:info("Loading PLT...", []),
|
||||
dialyzer_plt:from_file(PLT).
|
||||
|
||||
%% erlfmt-ignore
|
||||
find_remote_calls(_Opts) ->
|
||||
Query =
|
||||
"XC | (A - ["
|
||||
?IGNORED_APPS
|
||||
"]:App - ["
|
||||
?IGNORED_MODULES
|
||||
"]:Mod - ["
|
||||
?EXEMPTIONS
|
||||
"])\n"
|
||||
" || ((["
|
||||
?RPC_MODULES
|
||||
"] : Mod + ["
|
||||
?RPC_FUNCTIONS
|
||||
"]) - ["
|
||||
?IGNORED_RPC_CALLS
|
||||
"])",
|
||||
"XC | (A - ["?IGNORED_APPS"]:App - ["?IGNORED_MODULES"]:Mod - ["?EXEMPTIONS"])
|
||||
|| ((["?RPC_MODULES"] : Mod + ["?RPC_FUNCTIONS"]) - ["?IGNORED_RPC_CALLS"])",
|
||||
{ok, Calls} = xref:q(?XREF, Query),
|
||||
logger:info("Calls to RPC modules ~p", [Calls]),
|
||||
{Callers, _Callees} = lists:unzip(Calls),
|
||||
|
|
Loading…
Reference in New Issue