chore: some code format
This commit is contained in:
parent
402d3d97ae
commit
c777759707
|
@ -431,8 +431,10 @@ schema("/authentication/:id/users") ->
|
||||||
description => <<"List users in authenticator in global authentication chain">>,
|
description => <<"List users in authenticator in global authentication chain">>,
|
||||||
parameters => [
|
parameters => [
|
||||||
param_auth_id(),
|
param_auth_id(),
|
||||||
{page, mk(pos_integer(), #{in => query, desc => <<"Page Index">>, required => false})},
|
{page,
|
||||||
{limit, mk(pos_integer(), #{in => query, desc => <<"Page Limit">>, required => false})},
|
mk(pos_integer(), #{in => query, desc => <<"Page Index">>, required => false})},
|
||||||
|
{limit,
|
||||||
|
mk(pos_integer(), #{in => query, desc => <<"Page Limit">>, required => false})},
|
||||||
{like_username,
|
{like_username,
|
||||||
mk(binary(), #{
|
mk(binary(), #{
|
||||||
in => query,
|
in => query,
|
||||||
|
@ -481,8 +483,10 @@ schema("/listeners/:listener_id/authentication/:id/users") ->
|
||||||
parameters => [
|
parameters => [
|
||||||
param_listener_id(),
|
param_listener_id(),
|
||||||
param_auth_id(),
|
param_auth_id(),
|
||||||
{page, mk(pos_integer(), #{in => query, desc => <<"Page Index">>, required => false})},
|
{page,
|
||||||
{limit, mk(pos_integer(), #{in => query, desc => <<"Page Limit">>, required => false})}
|
mk(pos_integer(), #{in => query, desc => <<"Page Index">>, required => false})},
|
||||||
|
{limit,
|
||||||
|
mk(pos_integer(), #{in => query, desc => <<"Page Limit">>, required => false})}
|
||||||
],
|
],
|
||||||
responses => #{
|
responses => #{
|
||||||
200 => emqx_dashboard_swagger:schema_with_example(
|
200 => emqx_dashboard_swagger:schema_with_example(
|
||||||
|
|
|
@ -50,36 +50,55 @@ fields(exhook) ->
|
||||||
)}
|
)}
|
||||||
];
|
];
|
||||||
fields(server) ->
|
fields(server) ->
|
||||||
[ {name, sc(binary(),
|
[
|
||||||
#{ desc => "Name of the exhook server."
|
{name,
|
||||||
})}
|
sc(
|
||||||
, {enable, sc(boolean(),
|
binary(),
|
||||||
#{ default => true
|
#{desc => "Name of the exhook server."}
|
||||||
, desc => "Enable the exhook server."
|
)},
|
||||||
})}
|
{enable,
|
||||||
, {url, sc(binary(),
|
sc(
|
||||||
#{ desc => "URL of the gRPC server."
|
boolean(),
|
||||||
})}
|
#{
|
||||||
, {request_timeout, sc(duration(),
|
default => true,
|
||||||
#{ default => "5s"
|
desc => "Enable the exhook server."
|
||||||
, desc => "The timeout to request gRPC server."
|
}
|
||||||
})}
|
)},
|
||||||
, {failed_action, failed_action()}
|
{url,
|
||||||
, {ssl,
|
sc(
|
||||||
sc(ref(ssl_conf), #{})}
|
binary(),
|
||||||
, {auto_reconnect,
|
#{desc => "URL of the gRPC server."}
|
||||||
sc(hoconsc:union([false, duration()]),
|
)},
|
||||||
#{ default => "60s"
|
{request_timeout,
|
||||||
, desc => "Whether to automatically reconnect (initialize) the gRPC server.<br/>"
|
sc(
|
||||||
"When gRPC is not available, exhook tries to request the gRPC service at "
|
duration(),
|
||||||
"that interval and reinitialize the list of mounted hooks."
|
#{
|
||||||
})}
|
default => "5s",
|
||||||
, {pool_size,
|
desc => "The timeout to request gRPC server."
|
||||||
sc(pos_integer(),
|
}
|
||||||
#{ default => 8
|
)},
|
||||||
, example => 8
|
{failed_action, failed_action()},
|
||||||
, desc => "The process pool size for gRPC client."
|
{ssl, sc(ref(ssl_conf), #{})},
|
||||||
})}
|
{auto_reconnect,
|
||||||
|
sc(
|
||||||
|
hoconsc:union([false, duration()]),
|
||||||
|
#{
|
||||||
|
default => "60s",
|
||||||
|
desc =>
|
||||||
|
"Whether to automatically reconnect (initialize) the gRPC server.<br/>"
|
||||||
|
"When gRPC is not available, exhook tries to request the gRPC service at "
|
||||||
|
"that interval and reinitialize the list of mounted hooks."
|
||||||
|
}
|
||||||
|
)},
|
||||||
|
{pool_size,
|
||||||
|
sc(
|
||||||
|
pos_integer(),
|
||||||
|
#{
|
||||||
|
default => 8,
|
||||||
|
example => 8,
|
||||||
|
desc => "The process pool size for gRPC client."
|
||||||
|
}
|
||||||
|
)}
|
||||||
];
|
];
|
||||||
fields(ssl_conf) ->
|
fields(ssl_conf) ->
|
||||||
Schema = emqx_schema:client_ssl_opts_schema(#{}),
|
Schema = emqx_schema:client_ssl_opts_schema(#{}),
|
||||||
|
|
Loading…
Reference in New Issue