docs(emqx): add emqx_schema_in18.conf chinese

This commit is contained in:
JianBo He 2022-04-21 16:08:52 +08:00
parent bf7182ddc9
commit e1eb6591af
1 changed files with 95 additions and 55 deletions

View File

@ -6,7 +6,9 @@ emqx_schema {
For flexible configuration mapping, the <code>name</code> can be set to a listener's <code>zone</code> config. For flexible configuration mapping, the <code>name</code> can be set to a listener's <code>zone</code> config.
NOTE: A built-in zone named <code>default</code> is auto created and can not be deleted. NOTE: A built-in zone named <code>default</code> is auto created and can not be deleted.
""" """
zh: """ """ zh: """<code>zone</code> 是按<code>name</code> 分组的一组配置。
对于灵活的配置映射,可以将 <code>name</code> 设置为侦听器的 <code>zone</code> 配置。
注:名为 <code>default</code> 的内置区域是自动创建的,无法删除。"""
} }
} }
@ -15,77 +17,78 @@ NOTE: A built-in zone named <code>default</code> is auto created and can not be
en: """Global MQTT configuration. en: """Global MQTT configuration.
The configs here work as default values which can be overridden in <code>zone</code> configs The configs here work as default values which can be overridden in <code>zone</code> configs
""" """
zh: """ """ zh: """全局的 MQTT 配置项。
mqtt 下所有的配置作为全局的默认值存在,它可以被 <code>zone</code> 中的配置覆盖。"""
} }
} }
mqtt_idle_timeout { mqtt_idle_timeout {
desc { desc {
en: """Close TCP connections from the clients that have not sent MQTT CONNECT message within this interval.""" en: """Close TCP connections from the clients that have not sent MQTT CONNECT message within this interval."""
zh: """ """ zh: """关闭在此时间间隔内未发送 MQTT CONNECT 消息的客户端的 TCP 连接。"""
} }
} }
mqtt_max_packet_size { mqtt_max_packet_size {
desc { desc {
en: """Maximum MQTT packet size allowed.""" en: """Maximum MQTT packet size allowed."""
zh: """ """ zh: """允许的最大 MQTT 报文大小。"""
} }
} }
mqtt_max_clientid_len { mqtt_max_clientid_len {
desc { desc {
en: """"Maximum allowed length of MQTT clientId.""" en: """"Maximum allowed length of MQTT clientId."""
zh: """ """ zh: """允许的最大 MQTT Client ID 长度"""
} }
} }
mqtt_max_topic_levels { mqtt_max_topic_levels {
desc { desc {
en: """Maximum topic levels allowed.""" en: """Maximum topic levels allowed."""
zh: """ """ zh: """允许的 Topic 最大层级数"""
} }
} }
mqtt_max_qos_allowed { mqtt_max_qos_allowed {
desc { desc {
en: """Maximum QoS allowed.""" en: """Maximum QoS allowed."""
zh: """ """ zh: """允许的最大 QoS 等级。"""
} }
} }
mqtt_max_topic_alias { mqtt_max_topic_alias {
desc { desc {
en: """Maximum Topic Alias, 0 means no topic alias supported.""" en: """Maximum Topic Alias, 0 means no topic alias supported."""
zh: """ """ zh: """允许的最大主题别名数0 表示不支持主题别名。"""
} }
} }
mqtt_retain_available { mqtt_retain_available {
desc { desc {
en: """Support MQTT retained messages.""" en: """Support MQTT retained messages."""
zh: """ """ zh: """是否支持 retained 消息。"""
} }
} }
mqtt_wildcard_subscription { mqtt_wildcard_subscription {
desc { desc {
en: """Support MQTT Wildcard Subscriptions.""" en: """Support MQTT Wildcard Subscriptions."""
zh: """ """ zh: """是否支持主题的通配符订阅。"""
} }
} }
mqtt_shared_subscription { mqtt_shared_subscription {
desc { desc {
en: """Support MQTT Shared Subscriptions.""" en: """Support MQTT Shared Subscriptions."""
zh: """ """ zh: """是否支持 MQTT 共享订阅"""
} }
} }
mqtt_ignore_loop_deliver { mqtt_ignore_loop_deliver {
desc { desc {
en: """Ignore loop delivery of messages for MQTT v3.1.1.""" en: """Ignore loop delivery of messages for MQTT v3.1.1/v3.1.0."""
zh: """ """ zh: """是否为 MQTT v3.1.1/v3.1.0 客户端忽略接收自己发布出消息"""
} }
} }
@ -93,15 +96,15 @@ The configs here work as default values which can be overridden in <code>zone</c
desc { desc {
en: """Parse MQTT messages in strict mode. en: """Parse MQTT messages in strict mode.
When set to true, invalid utf8 strings in for example client ID, topic name, etc. will cause the client to be disconnected""" When set to true, invalid utf8 strings in for example client ID, topic name, etc. will cause the client to be disconnected"""
zh: """ """ zh: """是否以严格模式解析 MQTT 消息。
当设置为 true 时,例如客户端 ID、主题名称等中的无效 utf8 字符串将导致客户端断开连接。"""
} }
} }
mqtt_response_information { mqtt_response_information {
desc { desc {
en: """Specify the response information returned to the client. en: """Specify the response information returned to the client. This feature is disabled if is set to \"\"."""
This feature is disabled if is set to \"\".""" zh: """指定返回给客户端的响应信息。如果设置为 \"\",则禁用此功能。"""
zh: """ """
} }
} }
@ -109,77 +112,78 @@ This feature is disabled if is set to \"\"."""
desc { desc {
en: """'Server Keep Alive' of MQTT 5.0. en: """'Server Keep Alive' of MQTT 5.0.
If the server returns a 'Server Keep Alive' in the CONNACK packet, the client MUST use that value instead of the value it sent as the 'Keep Alive'.""" If the server returns a 'Server Keep Alive' in the CONNACK packet, the client MUST use that value instead of the value it sent as the 'Keep Alive'."""
zh: """ """ zh: """MQTT 5.0 的 'Server Keep Alive' 属性。
如果服务器在 CONNACK 数据包中返回'Server Keep Alive',则客户端必须使用该值作为实际的 'Keep Alive' 值。"""
} }
} }
mqtt_keepalive_backoff { mqtt_keepalive_backoff {
desc { desc {
en: """The backoff for MQTT keepalive timeout. The broker will close the connection after idling for 'Keepalive * backoff * 2'.""" en: """The backoff for MQTT keepalive timeout. The broker will close the connection after idling for 'Keepalive * backoff * 2'."""
zh: """ """ zh: """Broker 判定客户端 Keep Alive 超时的退避乘数。EMQX 将在'Keepalive * backoff * 2' 空闲后关闭连接。"""
} }
} }
mqtt_max_subscriptions { mqtt_max_subscriptions {
desc { desc {
en: """Maximum number of subscriptions allowed.""" en: """Maximum number of subscriptions allowed."""
zh: """ """ zh: """允许的每个客户端最大订阅数"""
} }
} }
mqtt_upgrade_qos { mqtt_upgrade_qos {
desc { desc {
en: """Force upgrade of QoS level according to subscription.""" en: """Force upgrade of QoS level according to subscription."""
zh: """ """ zh: """投递消息时,是否根据订阅主题时的 QoS 等级来强制提升派发的消息的 QoS 等级。"""
} }
} }
mqtt_max_inflight { mqtt_max_inflight {
desc { desc {
en: """Maximum size of the Inflight Window storing QoS1/2 messages delivered but un-acked.""" en: """Maximum size of the Inflight Window storing QoS1/2 messages delivered but un-acked."""
zh: """ """ zh: """飞行窗口的最大值。"""
} }
} }
mqtt_retry_interval { mqtt_retry_interval {
desc { desc {
en: """Retry interval for QoS1/2 message delivering.""" en: """Retry interval for QoS1/2 message delivering."""
zh: """ """ zh: """QoS1/2 消息的重新投递间隔。"""
} }
} }
mqtt_max_awaiting_rel { mqtt_max_awaiting_rel {
desc { desc {
en: """Maximum QoS2 packets (Client -> Broker) awaiting PUBREL.""" en: """Maximum QoS2 packets (Client -> Broker) awaiting PUBREL."""
zh: """ """ zh: """PUBREL (Client -> Broker) 最大等待队列长度。"""
} }
} }
mqtt_await_rel_timeout { mqtt_await_rel_timeout {
desc { desc {
en: """The QoS2 messages (Client -> Broker) will be dropped if awaiting PUBREL timeout.""" en: """The QoS2 messages (Client -> Broker) will be dropped if awaiting PUBREL timeout."""
zh: """ """ zh: """PUBREL (Client -> Broker) 最大等待时间,超时则会被丢弃。"""
} }
} }
mqtt_session_expiry_interval { mqtt_session_expiry_interval {
desc { desc {
en: """Default session expiry interval for MQTT V3.1.1 connections.""" en: """Default session expiry interval for MQTT V3.1.1 connections."""
zh: """ """ zh: """Session 默认超时时间。"""
} }
} }
mqtt_max_mqueue_len { mqtt_max_mqueue_len {
desc { desc {
en: """Maximum queue length. Enqueued messages when persistent client disconnected, or inflight window is full.""" en: """Maximum queue length. Enqueued messages when persistent client disconnected, or inflight window is full."""
zh: """ """ zh: """消息队列最大长度。持久客户端断开连接或飞行窗口已满时排队的消息长度。"""
} }
} }
mqtt_mqueue_priorities { mqtt_mqueue_priorities {
desc { desc {
en: """Topic priorities. en: """Topic priorities. Priority number [1-255]
There's no priority table by default, hence all messages are treated equal. Priority number [1-255] There's no priority table by default, hence all messages are treated equal.
**NOTE**: Comma and equal signs are not allowed for priority topic names. **NOTE**: Comma and equal signs are not allowed for priority topic names.
**NOTE**: Messages for topics not in the priority table are treated as either highest or lowest priority depending on the configured value for <code>mqtt.mqueue_default_priority</code>. **NOTE**: Messages for topics not in the priority table are treated as either highest or lowest priority depending on the configured value for <code>mqtt.mqueue_default_priority</code>.
@ -188,28 +192,37 @@ There's no priority table by default, hence all messages are treated equal. Prio
To configure <code>\"topic/1\" > \"topic/2\"</code>: To configure <code>\"topic/1\" > \"topic/2\"</code>:
<code>mqueue_priorities: {\"topic/1\": 10, \"topic/2\": 8}</code> <code>mqueue_priorities: {\"topic/1\": 10, \"topic/2\": 8}</code>
""" """
zh: """ """ zh: """主题优先级。取值范围 [1-255]
默认优先级表为空,即所有的主题优先级相同。
注:优先主题名称中不支持使用逗号和等号。
注:不在此列表中的主题,被视为最高/最低优先级,这取决于<code>mqtt.mqueue_default_priority</code> 的配置
示例:
配置 <code>\"topic/1\" > \"topic/2\"</code>:
<code>mqueue_priorities: {\"topic/1\": 10, \"topic/2\": 8}</code>
"""
} }
} }
mqtt_mqueue_default_priority { mqtt_mqueue_default_priority {
desc { desc {
en: """Default to the highest priority for topics not matching priority table.""" en: """Default to the highest priority for topics not matching priority table."""
zh: """ """ zh: """主题默认的优先级,不在 <code>mqtt.mqueue_priorities</code> 中的主题将会使用该优先级。"""
} }
} }
mqtt_mqueue_store_qos0 { mqtt_mqueue_store_qos0 {
desc { desc {
en: """Support enqueue QoS0 messages.""" en: """Support enqueue QoS0 messages."""
zh: """ """ zh: """消息队列是否存储 QoS0 消息。"""
} }
} }
mqtt_use_username_as_clientid { mqtt_use_username_as_clientid {
desc { desc {
en: """Replace client ID with the username.""" en: """Replace client ID with the username."""
zh: """ """ zh: """是否使用 Client ID 替换 Username。"""
} }
} }
@ -217,7 +230,7 @@ To configure <code>\"topic/1\" > \"topic/2\"</code>:
desc { desc {
en: """Use the CN, DN or CRT field from the client certificate as a username. en: """Use the CN, DN or CRT field from the client certificate as a username.
Only works for the TLS connection.""" Only works for the TLS connection."""
zh: """ """ zh: """使用客户端证书中的 CN, DN 字段或整个证书来作为客户端用户名。"""
} }
} }
@ -225,21 +238,21 @@ Only works for the TLS connection."""
desc { desc {
en: """Use the CN, DN or CRT field from the client certificate as a clientid. en: """Use the CN, DN or CRT field from the client certificate as a clientid.
Only works for the TLS connection.""" Only works for the TLS connection."""
zh: """ """ zh: """使用客户端证书中的 CN, DN 字段或整个证书来作为客户端 ID。"""
} }
} }
broker { broker {
desc { desc {
en: """"Message broker options.""" en: """"Message broker options."""
zh: """ """ zh: """Broker 相关配置项。"""
} }
} }
broker_enable_session_registry { broker_enable_session_registry {
desc { desc {
en: """Enable session registry""" en: """Enable session registry"""
zh: """ """ zh: """是否启用 Session Registry"""
} }
} }
@ -252,7 +265,12 @@ Only works for the TLS connection."""
- `all`: lock the session on all the nodes in the cluster - `all`: lock the session on all the nodes in the cluster
""" """
zh: """ """ zh: """Session 在集群中的锁策略。
- `loca`: 仅锁本节点的 Session
- `one`: 任选一个其它节点加锁
- `quorum`: 选择集群中半数以上的节点加锁
- `all`: 选择所有节点加锁
"""
} }
} }
@ -265,7 +283,12 @@ Only works for the TLS connection."""
- `hash`: select the subscribers by the hash of `clientIds` - `hash`: select the subscribers by the hash of `clientIds`
""" """
zh: """ """ zh: """共享订阅消息派发策略。
- `random`: 随机挑选一个共享订阅者派发
- `round_robin`: 使用 round-robin 策略派发
- `sticky`: 总是使用上次选中的订阅者派发,直到它断开连接
- `hash`: 使用发送者的 Client ID 进行 Hash 来选择订阅者
"""
} }
} }
@ -275,14 +298,16 @@ Only works for the TLS connection."""
This should allow messages to be dispatched to a different subscriber in the group in case the picked (based on `shared_subscription_strategy`) subscriber is offline. This should allow messages to be dispatched to a different subscriber in the group in case the picked (based on `shared_subscription_strategy`) subscriber is offline.
""" """
zh: """ """ zh: """启用/禁用 QoS1 和 QoS2 消息的共享派发确认。
开启后,允许将消息从未及时回复 ACK 的订阅者 (例如,客户端离线)重新派发给另外一个订阅者。
"""
} }
} }
broker_route_batch_clean { broker_route_batch_clean {
desc { desc {
en: """Enable batch clean for deleted routes.""" en: """Enable batch clean for deleted routes."""
zh: """ """ zh: """是否开启批量清除路由。"""
} }
} }
@ -296,7 +321,14 @@ NOTE: when changing from/to `global` lock, it requires all nodes in the cluster
- `tab`: mnesia transactional updates with table lock. Recommended for a cluster setup. - `tab`: mnesia transactional updates with table lock. Recommended for a cluster setup.
- `global`: updates are protected with a global lock. Recommended for large clusters. - `global`: updates are protected with a global lock. Recommended for large clusters.
""" """
zh: """ """ zh: """通配主题订阅/取消订阅性能调优。
建议仅当通配符主题较多时才更改此参数。
注:当从/更改为 `global` 锁时,它要求集群中的所有节点在更改之前停止。
- `key`: 为 Mnesia 事务涉及到的每个 key 上锁,建议单节点时使用。
- `tab`: 为 Mnesia 事务涉及到的表上锁,建议在集群中使用。
- `global`: 所以更新操作都被全局的锁保护,仅建议在超大规模集群中使用。
"""
} }
} }
@ -308,21 +340,26 @@ Topic match performance (when publishing) may degrade if messages are mostly pub
NOTE: This is a cluster-wide configuration. It requires all nodes to be stopped before changing it. NOTE: This is a cluster-wide configuration. It requires all nodes to be stopped before changing it.
""" """
zh: """ """ zh: """是否开启主题表压缩存储。
启用它会显着提高通配符主题订阅率,如果通配符主题具有唯一前缀,例如:'sensor/{{id}}/+/',其中每个订阅者的 ID 是唯一的。
如果消息主要发布到具有大量级别的主题,则主题匹配性能(发布时)可能会降低。
注意:这是一个集群范围的配置。 它要求在更改之前停止所有节点。
"""
} }
} }
sys_topics { sys_topics {
desc { desc {
en: """ """ en: """System topics configuration."""
zh: """ """ zh: """系统主题配置。"""
} }
} }
sys_msg_interval { sys_msg_interval {
desc { desc {
en: """Time interval of publishing `$SYS` messages.""" en: """Time interval of publishing `$SYS` messages."""
zh: """ """ zh: """发送 `$SYS` 主题的间隔时间。"""
} }
} }
@ -332,42 +369,45 @@ NOTE: This is a cluster-wide configuration. It requires all nodes to be stopped
- `$SYS/brokers/<node>/uptime` - `$SYS/brokers/<node>/uptime`
- `$SYS/brokers/<node>/datetime` - `$SYS/brokers/<node>/datetime`
""" """
zh: """ """ zh: """发送心跳系统消息的间隔时间,它包括:
- `$SYS/brokers/<node>/uptime`
- `$SYS/brokers/<node>/datetime`
"""
} }
} }
sys_event_messages { sys_event_messages {
desc { desc {
en: """ """ en: """Client events messages"""
zh: """ """ zh: """客户端事件消息"""
} }
} }
sys_event_client_connected { sys_event_client_connected {
desc { desc {
en: """Enable to publish client connected event messages""" en: """Enable to publish client connected event messages"""
zh: """ """ zh: """是否开启客户端已连接事件消息。"""
} }
} }
sys_event_client_disconnected { sys_event_client_disconnected {
desc { desc {
en: """Enable to publish client disconnected event messages.""" en: """Enable to publish client disconnected event messages."""
zh: """ """ zh: """是否开启客户端已断开连接事件消息。"""
} }
} }
sys_event_client_subscribed { sys_event_client_subscribed {
desc { desc {
en: """Enable to publish event message that client subscribed a topic successfully.""" en: """Enable to publish event message that client subscribed a topic successfully."""
zh: """ """ zh: """是否开启客户端已成功订阅主题事件消息。"""
} }
} }
sys_event_client_unsubscribed { sys_event_client_unsubscribed {
desc { desc {
en: """Enable to publish event message that client unsubscribed a topic successfully.""" en: """Enable to publish event message that client unsubscribed a topic successfully."""
zh: """ """ zh: """是否开启客户端已成功取消订阅主题事件消息。"""
} }
} }
} }