chore: reslove confilt for sync release-50 to master
This commit is contained in:
parent
9d893b49eb
commit
bc1bdae55d
|
@ -80,8 +80,10 @@ on_start(
|
|||
config => redact(Config)
|
||||
}),
|
||||
|
||||
{Schema, Server} = get_host_schema(to_str(Url)),
|
||||
#{hostname := Host, port := Port} = emqx_schema:parse_server(Server, ?DYNAMO_HOST_OPTIONS),
|
||||
{Schema, Server, DefaultPort} = get_host_info(to_str(Url)),
|
||||
#{hostname := Host, port := Port} = emqx_schema:parse_server(Server, #{
|
||||
default_port => DefaultPort
|
||||
}),
|
||||
|
||||
Options = [
|
||||
{config, #{
|
||||
|
@ -142,8 +144,10 @@ on_batch_query_async(InstanceId, [{send_message, _} | _] = Query, ReplyCtx, Stat
|
|||
on_batch_query_async(_InstanceId, Query, _Reply, _State) ->
|
||||
{error, {unrecoverable_error, {invalid_request, Query}}}.
|
||||
|
||||
on_get_status(_InstanceId, #{pool_name := PoolName}) ->
|
||||
Health = emqx_resource_pool:health_check_workers(PoolName, fun ?MODULE:do_get_status/1),
|
||||
on_get_status(_InstanceId, #{pool_name := Pool}) ->
|
||||
Health = emqx_resource_pool:health_check_workers(
|
||||
Pool, {emqx_ee_connector_dynamo_client, is_connected, []}
|
||||
),
|
||||
status_result(Health).
|
||||
|
||||
status_result(_Status = true) -> connected;
|
||||
|
|
|
@ -96,8 +96,10 @@ on_start(
|
|||
connector => InstanceId,
|
||||
config => redact(Config)
|
||||
}),
|
||||
Config = maps:merge(default_security_info(), Config1),
|
||||
#{hostname := Host, port := Port} = emqx_schema:parse_server(Server, ?ROCKETMQ_HOST_OPTIONS),
|
||||
Servers = lists:map(
|
||||
fun(#{hostname := Host, port := Port}) -> {Host, Port} end,
|
||||
emqx_schema:parse_servers(BinServers, ?ROCKETMQ_HOST_OPTIONS)
|
||||
),
|
||||
ClientId = client_id(InstanceId),
|
||||
|
||||
TopicTks = emqx_plugin_libs_rule:preproc_tmpl(Topic),
|
||||
|
|
|
@ -304,11 +304,10 @@ on_batch_query_async(InstanceId, Requests, ReplyFunAndArgs, State) ->
|
|||
),
|
||||
do_query(InstanceId, Requests, ?ASYNC_QUERY_MODE(ReplyFunAndArgs), State).
|
||||
|
||||
on_get_status(_InstanceId, #{pool_name := PoolName, resource_opts := ResourceOpts} = _State) ->
|
||||
RequestTimeout = ?REQUEST_TIMEOUT(ResourceOpts),
|
||||
on_get_status(_InstanceId, #{pool_name := PoolName} = _State) ->
|
||||
Health = emqx_resource_pool:health_check_workers(
|
||||
PoolName,
|
||||
{?MODULE, do_get_status, []},
|
||||
{?MODULE, do_get_status, []}
|
||||
),
|
||||
status_result(Health).
|
||||
|
||||
|
|
Loading…
Reference in New Issue