fix: set bpapi version to 1

This commit is contained in:
Stefan Strigler 2023-10-11 10:53:15 +02:00 committed by Zaiming (Stone) Shi
parent cb8691438a
commit a9a7f4ae3a
2 changed files with 3 additions and 4 deletions

View File

@ -13,6 +13,7 @@
{emqx_conf,1}.
{emqx_conf,2}.
{emqx_conf,3}.
{emqx_connector, 1}.
{emqx_dashboard,1}.
{emqx_delayed,1}.
{emqx_delayed,2}.

View File

@ -744,7 +744,7 @@ do_bpapi_call(Node, Call, Args) ->
do_bpapi_call_vsn(SupportedVersion, Call, Args) ->
case lists:member(SupportedVersion, supported_versions(Call)) of
true ->
apply(emqx_connector_proto_v4, Call, Args);
apply(emqx_connector_proto_v1, Call, Args);
false ->
{error, not_implemented}
end.
@ -754,9 +754,7 @@ maybe_unwrap({error, not_implemented}) ->
maybe_unwrap(RpcMulticallResult) ->
emqx_rpc:unwrap_erpc(RpcMulticallResult).
supported_versions(start_connector_to_node) -> [2, 3, 4];
supported_versions(start_connectors_to_all_nodes) -> [2, 3, 4];
supported_versions(_Call) -> [1, 2, 3, 4].
supported_versions(_Call) -> [1].
redact(Term) ->
emqx_utils:redact(Term).