chore(schema): Fix grammar
This commit is contained in:
parent
e24ab5588a
commit
f0455b32f8
|
@ -897,7 +897,7 @@ conn_congestion {
|
||||||
## get "congested", because there's too many packets to sent.
|
## get "congested", because there's too many packets to sent.
|
||||||
## The socket tries to buffer the packets until the buffer is
|
## The socket tries to buffer the packets until the buffer is
|
||||||
## full. If more packets come after that, the packets will be
|
## full. If more packets come after that, the packets will be
|
||||||
## "pending" in a queue and we consider the connection is
|
## "pending" in a queue, and we consider the connection is
|
||||||
## "congested".
|
## "congested".
|
||||||
##
|
##
|
||||||
## Enable this to send an alarm when there's any bytes pending in
|
## Enable this to send an alarm when there's any bytes pending in
|
||||||
|
|
|
@ -1767,7 +1767,7 @@ desc("conn_congestion") ->
|
||||||
"get \"congested\", because there are too many packets to be sent.\n"
|
"get \"congested\", because there are too many packets to be sent.\n"
|
||||||
"The socket tries to buffer the packets until the buffer is\n"
|
"The socket tries to buffer the packets until the buffer is\n"
|
||||||
"full. If more packets arrive after that, the packets will be\n"
|
"full. If more packets arrive after that, the packets will be\n"
|
||||||
"\"pending\" in the queue and we consider the connection\n"
|
"\"pending\" in the queue, and we consider the connection\n"
|
||||||
"congested.\n\n"
|
"congested.\n\n"
|
||||||
"Note: `sndbuf` can be set to larger value if the\n"
|
"Note: `sndbuf` can be set to larger value if the\n"
|
||||||
"alarm is triggered too often.\n"
|
"alarm is triggered too often.\n"
|
||||||
|
|
|
@ -8,7 +8,7 @@ Under the premise that the subject rewriting function is enabled, when EMQX rece
|
||||||
it will use the subject of the message to sequentially match the subject filter part of the rule in the configuration file. If the match is successful,
|
it will use the subject of the message to sequentially match the subject filter part of the rule in the configuration file. If the match is successful,
|
||||||
the regular expression is used to extract the information in the subject, and then replaced with the target expression to form a new subject.
|
the regular expression is used to extract the information in the subject, and then replaced with the target expression to form a new subject.
|
||||||
Variables in the format of `$N` can be used in the target expression to match the elements extracted from the regular expression.
|
Variables in the format of `$N` can be used in the target expression to match the elements extracted from the regular expression.
|
||||||
The value of `$N` is the Nth element extracted from the regular expression. For example, $1 is the regular expression. The first element extracted by the expression.
|
The value of `$N` is the Nth element extracted from the regular expression. For example, `$1` is the regular expression. The first element extracted by the expression.
|
||||||
It should be noted that EMQX uses reverse order to read the rewrite rules in the configuration file.
|
It should be noted that EMQX uses reverse order to read the rewrite rules in the configuration file.
|
||||||
When a topic can match the topic filter of multiple topic rewrite rules at the same time, EMQX will only use the first rule it matches. Rewrite.
|
When a topic can match the topic filter of multiple topic rewrite rules at the same time, EMQX will only use the first rule it matches. Rewrite.
|
||||||
If the regular expression in this rule does not match the subject of the MQTT message, the rewriting will fail, and no other rules will be attempted for rewriting.
|
If the regular expression in this rule does not match the subject of the MQTT message, the rewriting will fail, and no other rules will be attempted for rewriting.
|
||||||
|
@ -17,7 +17,7 @@ Therefore, users need to carefully design MQTT message topics and topic rewritin
|
||||||
重写规则分为 Pub 规则和 Sub 规则,Pub 规则匹配 PUSHLISH 报文携带的主题,Sub 规则匹配 SUBSCRIBE、UNSUBSCRIBE 报文携带的主题。
|
重写规则分为 Pub 规则和 Sub 规则,Pub 规则匹配 PUSHLISH 报文携带的主题,Sub 规则匹配 SUBSCRIBE、UNSUBSCRIBE 报文携带的主题。
|
||||||
每条重写规则都由主题过滤器、正则表达式、目标表达式三部分组成。
|
每条重写规则都由主题过滤器、正则表达式、目标表达式三部分组成。
|
||||||
在主题重写功能开启的前提下,EMQX 在收到诸如 PUBLISH 报文等带有主题的 MQTT 报文时,将使用报文中的主题去依次匹配配置文件中规则的主题过滤器部分,一旦成功匹配,则使用正则表达式提取主题中的信息,然后替换至目标表达式以构成新的主题。
|
在主题重写功能开启的前提下,EMQX 在收到诸如 PUBLISH 报文等带有主题的 MQTT 报文时,将使用报文中的主题去依次匹配配置文件中规则的主题过滤器部分,一旦成功匹配,则使用正则表达式提取主题中的信息,然后替换至目标表达式以构成新的主题。
|
||||||
目标表达式中可以使用 `$N` 这种格式的变量匹配正则表达中提取出来的元素,`$N` 的值为正则表达式中提取出来的第 N 个元素,比如 $1 即为正则表达式提取的第一个元素。
|
目标表达式中可以使用 `$N` 这种格式的变量匹配正则表达中提取出来的元素,`$N` 的值为正则表达式中提取出来的第 N 个元素,比如 `$1` 即为正则表达式提取的第一个元素。
|
||||||
需要注意的是,EMQX 使用倒序读取配置文件中的重写规则,当一条主题可以同时匹配多条主题重写规则的主题过滤器时,EMQX 仅会使用它匹配到的第一条规则进行重写,如果该条规则中的正则表达式与 MQTT 报文主题不匹配,则重写失败,不会再尝试使用其他的规则进行重写。
|
需要注意的是,EMQX 使用倒序读取配置文件中的重写规则,当一条主题可以同时匹配多条主题重写规则的主题过滤器时,EMQX 仅会使用它匹配到的第一条规则进行重写,如果该条规则中的正则表达式与 MQTT 报文主题不匹配,则重写失败,不会再尝试使用其他的规则进行重写。
|
||||||
因此用户在使用时需要谨慎的设计 MQTT 报文主题以及主题重写规则。"""
|
因此用户在使用时需要谨慎的设计 MQTT 报文主题以及主题重写规则。"""
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue