chore: try to fix spellcheck
This commit is contained in:
parent
d76ed585b0
commit
2d958beae9
|
@ -33,8 +33,8 @@ fields(ocpp) ->
|
||||||
desc => ?DESC(heartbeat_checking_times_backoff)
|
desc => ?DESC(heartbeat_checking_times_backoff)
|
||||||
}
|
}
|
||||||
)},
|
)},
|
||||||
{upstream, sc(ref(upstream), #{desc => ?DESC(upstream)})},
|
{upstream, sc(ref(upstream), #{})},
|
||||||
{dnstream, sc(ref(dnstream), #{desc => ?DESC(dnstream)})},
|
{dnstream, sc(ref(dnstream), #{})},
|
||||||
{message_format_checking,
|
{message_format_checking,
|
||||||
sc(
|
sc(
|
||||||
hoconsc:union([all, upstream_only, dnstream_only, disable]),
|
hoconsc:union([all, upstream_only, dnstream_only, disable]),
|
||||||
|
@ -59,7 +59,7 @@ fields(ocpp) ->
|
||||||
desc => ?DESC(json_schema_id_prefix)
|
desc => ?DESC(json_schema_id_prefix)
|
||||||
}
|
}
|
||||||
)},
|
)},
|
||||||
{listeners, sc(ref(ws_listeners), #{desc => ?DESC(ws_listeners)})}
|
{listeners, sc(ref(ws_listeners), #{})}
|
||||||
] ++ emqx_gateway_schema:gateway_common_options();
|
] ++ emqx_gateway_schema:gateway_common_options();
|
||||||
fields(ws_listeners) ->
|
fields(ws_listeners) ->
|
||||||
[
|
[
|
||||||
|
@ -67,9 +67,11 @@ fields(ws_listeners) ->
|
||||||
{wss, sc(map(name, ref(wss_listener)), #{})}
|
{wss, sc(map(name, ref(wss_listener)), #{})}
|
||||||
];
|
];
|
||||||
fields(ws_listener) ->
|
fields(ws_listener) ->
|
||||||
emqx_gateway_schema:ws_listener() ++ [{websocket, sc(ref(websocket), #{})}];
|
emqx_gateway_schema:ws_listener() ++
|
||||||
|
[{websocket, sc(ref(websocket), #{})}];
|
||||||
fields(wss_listener) ->
|
fields(wss_listener) ->
|
||||||
emqx_gateway_schema:wss_listener() ++ [{websocket, sc(ref(websocket), #{})}];
|
emqx_gateway_schema:wss_listener() ++
|
||||||
|
[{websocket, sc(ref(websocket), #{})}];
|
||||||
fields(websocket) ->
|
fields(websocket) ->
|
||||||
DefaultPath = <<"/ocpp">>,
|
DefaultPath = <<"/ocpp">>,
|
||||||
SubProtocols = <<"ocpp1.6, ocpp2.0">>,
|
SubProtocols = <<"ocpp1.6, ocpp2.0">>,
|
||||||
|
@ -125,15 +127,15 @@ fields(upstream) ->
|
||||||
];
|
];
|
||||||
fields(dnstream) ->
|
fields(dnstream) ->
|
||||||
[
|
[
|
||||||
{strit_mode,
|
%%{strit_mode,
|
||||||
sc(
|
%% sc(
|
||||||
boolean(),
|
%% boolean(),
|
||||||
#{
|
%% #{
|
||||||
required => false,
|
%% required => false,
|
||||||
default => false,
|
%% default => false,
|
||||||
desc => ?DESC(dnstream_strit_mode)
|
%% desc => ?DESC(dnstream_strit_mode)
|
||||||
}
|
%% }
|
||||||
)},
|
%% )},
|
||||||
{topic,
|
{topic,
|
||||||
sc(
|
sc(
|
||||||
string(),
|
string(),
|
||||||
|
@ -165,6 +167,29 @@ fields(dnstream) ->
|
||||||
|
|
||||||
desc(ocpp) ->
|
desc(ocpp) ->
|
||||||
"The OCPP gateway";
|
"The OCPP gateway";
|
||||||
|
desc(upstream) ->
|
||||||
|
"Upload stream topic to notify third-party system what's messages/events reported by "
|
||||||
|
"Charge Point. Available placeholders:\n"
|
||||||
|
"- <code>cid</code>: Charge Point ID\n"
|
||||||
|
"- <code>clientid</code>: Equal to Charge Point ID\n"
|
||||||
|
"- <code>action</code>: Message Name in OCPP";
|
||||||
|
desc(dnstream) ->
|
||||||
|
"Download stream topic to forward the system message to device. Available placeholders:\n"
|
||||||
|
"- <code>cid</code>: Charge Point ID\n"
|
||||||
|
"- <code>clientid</code>: Equal to Charge Point ID\n"
|
||||||
|
"- <code>action</code>: Message Name in OCPP";
|
||||||
|
desc(ws_listeners) ->
|
||||||
|
"Websocket listeners";
|
||||||
|
desc(ws_listener) ->
|
||||||
|
"Websocket listener";
|
||||||
|
desc(ws) ->
|
||||||
|
"Websocket listener";
|
||||||
|
desc(wss_listener) ->
|
||||||
|
"Websocket over TLS listener";
|
||||||
|
desc(wss) ->
|
||||||
|
"Websocket over TLS listener";
|
||||||
|
desc(websocket) ->
|
||||||
|
"Websocket options";
|
||||||
desc(_) ->
|
desc(_) ->
|
||||||
undefined.
|
undefined.
|
||||||
|
|
||||||
|
|
|
@ -114,4 +114,84 @@ udp_listener_udp_opts.desc:
|
||||||
udp_listeners.desc:
|
udp_listeners.desc:
|
||||||
"""Settings for the UDP listeners."""
|
"""Settings for the UDP listeners."""
|
||||||
|
|
||||||
|
fields_ws_opts_path.desc:
|
||||||
|
"""WebSocket's MQTT protocol path. So the address of EMQX Broker's WebSocket is:
|
||||||
|
<code>ws://{ip}:{port}/mqtt</code>"""
|
||||||
|
|
||||||
|
fields_ws_opts_path.label:
|
||||||
|
"""WS MQTT Path"""
|
||||||
|
|
||||||
|
fields_ws_opts_piggyback.desc:
|
||||||
|
"""Whether a WebSocket message is allowed to contain multiple MQTT packets."""
|
||||||
|
|
||||||
|
fields_ws_opts_piggyback.label:
|
||||||
|
"""MQTT Piggyback"""
|
||||||
|
|
||||||
|
fields_ws_opts_compress.desc:
|
||||||
|
"""If <code>true</code>, compress WebSocket messages using <code>zlib</code>.<br/>
|
||||||
|
The configuration items under <code>deflate_opts</code> belong to the compression-related parameter configuration."""
|
||||||
|
|
||||||
|
fields_ws_opts_compress.label:
|
||||||
|
"""Ws compress"""
|
||||||
|
|
||||||
|
fields_ws_opts_idle_timeout.desc:
|
||||||
|
"""Close transport-layer connections from the clients that have not sent MQTT CONNECT message within this interval."""
|
||||||
|
|
||||||
|
fields_ws_opts_idle_timeout.label:
|
||||||
|
"""WS idle timeout"""
|
||||||
|
|
||||||
|
fields_ws_opts_max_frame_size.desc:
|
||||||
|
"""The maximum length of a single MQTT packet."""
|
||||||
|
|
||||||
|
fields_ws_opts_max_frame_size.label:
|
||||||
|
"""Max frame size"""
|
||||||
|
|
||||||
|
fields_ws_opts_fail_if_no_subprotocol.desc:
|
||||||
|
"""If <code>true</code>, the server will return an error when
|
||||||
|
the client does not carry the <code>Sec-WebSocket-Protocol</code> field.
|
||||||
|
<br/>Note: WeChat applet needs to disable this verification."""
|
||||||
|
|
||||||
|
fields_ws_opts_fail_if_no_subprotocol.label:
|
||||||
|
"""Fail if no subprotocol"""
|
||||||
|
|
||||||
|
fields_ws_opts_supported_subprotocols.desc:
|
||||||
|
"""Comma-separated list of supported subprotocols."""
|
||||||
|
|
||||||
|
fields_ws_opts_supported_subprotocols.label:
|
||||||
|
"""Supported subprotocols"""
|
||||||
|
|
||||||
|
fields_ws_opts_check_origin_enable.desc:
|
||||||
|
"""If <code>true</code>, <code>origin</code> HTTP header will be
|
||||||
|
validated against the list of allowed origins configured in <code>check_origins</code>
|
||||||
|
parameter."""
|
||||||
|
|
||||||
|
fields_ws_opts_check_origin_enable.label:
|
||||||
|
"""Check origin"""
|
||||||
|
|
||||||
|
fields_ws_opts_allow_origin_absence.desc:
|
||||||
|
"""If <code>false</code> and <code>check_origin_enable</code> is
|
||||||
|
<code>true</code>, the server will reject requests that don't have <code>origin</code>
|
||||||
|
HTTP header."""
|
||||||
|
|
||||||
|
fields_ws_opts_allow_origin_absence.label:
|
||||||
|
"""Allow origin absence"""
|
||||||
|
|
||||||
|
fields_ws_opts_check_origins.desc:
|
||||||
|
"""List of allowed origins.<br/>See <code>check_origin_enable</code>."""
|
||||||
|
|
||||||
|
fields_ws_opts_check_origins.label:
|
||||||
|
"""Allowed origins"""
|
||||||
|
fields_ws_opts_proxy_port_header.desc:
|
||||||
|
"""HTTP header used to pass information about the client port. Relevant when the EMQX cluster is deployed behind a load-balancer."""
|
||||||
|
|
||||||
|
fields_ws_opts_proxy_port_header.label:
|
||||||
|
"""Proxy port header"""
|
||||||
|
|
||||||
|
fields_ws_opts_proxy_address_header.desc:
|
||||||
|
"""HTTP header used to pass information about the client IP address.
|
||||||
|
Relevant when the EMQX cluster is deployed behind a load-balancer."""
|
||||||
|
|
||||||
|
fields_ws_opts_proxy_address_header.label:
|
||||||
|
"""Proxy address header"""
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,47 @@
|
||||||
|
emqx_ocpp_schema {
|
||||||
|
|
||||||
|
default_heartbeat_interval.desc:
|
||||||
|
"""The default Heartbeat time interval"""
|
||||||
|
|
||||||
|
heartbeat_checking_times_backoff.desc:
|
||||||
|
"""The backoff for heartbeat checking times"""
|
||||||
|
|
||||||
|
message_format_checking.desc:
|
||||||
|
"""Whether to enable message format legality checking.
|
||||||
|
EMQX checks the message format of the upload stream and download stream against the
|
||||||
|
format defined in json-schema.
|
||||||
|
When the check fails, emqx will reply with a corresponding answer message.
|
||||||
|
|
||||||
|
The checking strategy can be one of the following values:
|
||||||
|
- <code>all</code>: check all messages
|
||||||
|
- <code>upstream_only</code>: check upload stream messages only
|
||||||
|
- <code>dnstream_only</code>: check download stream messages only
|
||||||
|
- <code>disable</code>: don't check any messages"""
|
||||||
|
|
||||||
|
upstream_topic.desc:
|
||||||
|
"""The topic for Upload stream Call Request messages."""
|
||||||
|
|
||||||
|
upstream_topic_override_mapping.desc:
|
||||||
|
"""Upload stream topic override mapping by Message Name."""
|
||||||
|
|
||||||
|
upstream_reply_topic.desc:
|
||||||
|
"""The topic for Upload stream Reply messages."""
|
||||||
|
|
||||||
|
upstream_error_topic.desc:
|
||||||
|
"""The topic for Upload stream error topic."""
|
||||||
|
|
||||||
|
dnstream_topic.desc:
|
||||||
|
"""Download stream topic to receive request/control messages from third-party system.
|
||||||
|
This value is a wildcard topic name that subscribed by every connected Charge Point."""
|
||||||
|
|
||||||
|
dnstream_max_mqueue_len.desc:
|
||||||
|
"""The maximum message queue length for download stream message delivery."""
|
||||||
|
|
||||||
|
json_schema_dir.desc:
|
||||||
|
"""JSON Schema directory for OCPP message definitions.
|
||||||
|
Default: ${application}/priv/schemas"""
|
||||||
|
|
||||||
|
json_schema_id_prefix.desc:
|
||||||
|
"""The ID prefix for the OCPP message schemas."""
|
||||||
|
|
||||||
|
}
|
|
@ -289,3 +289,8 @@ Keyspace
|
||||||
OpenTSDB
|
OpenTSDB
|
||||||
saml
|
saml
|
||||||
idp
|
idp
|
||||||
|
ocpp
|
||||||
|
OCPP
|
||||||
|
dnstream
|
||||||
|
upstream
|
||||||
|
priv
|
||||||
|
|
Loading…
Reference in New Issue