Merge pull request #7709 from terry-xiaoyu/emqx_schema_i18n

doc: update i18n for emqx_schema.erl
This commit is contained in:
Xinyu Liu 2022-04-22 08:33:11 +08:00 committed by GitHub
commit ae49c0bad5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 628 additions and 107 deletions

View File

@ -1,5 +1,585 @@
emqx_schema {
force_shutdown_enable {
desc {
en: "Enable `force_shutdown` feature."
zh: "启用 `force_shutdown` 功能"
}
label {
en: "Enable `force_shutdown` feature."
zh: "启用 `force_shutdown` 功能"
}
}
force_shutdown_max_message_queue_len {
desc {
en: "Maximum message queue length."
zh: "消息队列的最大长度"
}
label {
en: "Maximum message queue length."
zh: "消息队列的最大长度"
}
}
force_shutdown_max_heap_size {
desc {
en: "Total heap size"
zh: "Heap 的总大小"
}
label {
en: "Total heap size"
zh: "Heap 的总大小"
}
}
overload_protection_enable {
desc {
en: "React on system overload or not"
zh: "是否对系统过载做出反应"
}
label {
en: "React on system overload or not"
zh: "是否对系统过载做出反应"
}
}
overload_protection_backoff_delay {
desc {
en: "Some unimportant tasks could be delayed "
"for execution, here set the delays in ms"
zh: "一些不重要的任务可能会延迟执行,以毫秒为单位设置延迟"
}
label {
en: "Delay Time"
zh: "延迟时间"
}
}
overload_protection_backoff_gc {
desc {
en: "Skip forceful GC if necessary"
zh: "如有必要跳过强制GC"
}
label {
en: "Skip GC"
zh: "跳过GC"
}
}
overload_protection_backoff_hibernation {
desc {
en: "Skip process hibernation if necessary"
zh: "如有必要,跳过进程休眠"
}
label {
en: "Skip hibernation"
zh: "跳过休眠"
}
}
overload_protection_backoff_new_conn {
desc {
en: "Close new incoming connections if necessary"
zh: "如有必要,关闭新进来的连接"
}
label {
en: "Close new connections"
zh: "关闭新连接"
}
}
conn_congestion_enable_alarm {
desc {
en: "Enable or disable connection congestion alarm."
zh: "启用或者禁用连接阻塞告警功能"
}
label {
en: "Enable/disable congestion alarm"
zh: "启用/禁用阻塞告警"
}
}
conn_congestion_min_alarm_sustain_duration {
desc {
en: "Minimal time before clearing the alarm.\n\n"
"The alarm is cleared only when there's no pending data in\n"
"the queue, and at least `min_alarm_sustain_duration`\n"
"milliseconds passed since the last time we considered the connection \"congested\".\n\n"
"This is to avoid clearing and raising the alarm again too often."
zh: "清除警报前的最短时间。\n\n"
"只有当队列中没有挂起的数据,并且连接至少被堵塞了 \"min_alarm_sustain_duration\" 毫秒时,\n"
"报警才会被清除。这是为了避免太频繁地清除和再次发出警报."
}
label {
en: "Sustain duration"
zh: "告警维持时间"
}
}
force_gc_enable {
desc {
en: "Enable forced garbage collection."
zh: "启用强制垃圾回收"
}
label {
en: "Enable forced garbage collection."
zh: "启用强制垃圾回收"
}
}
force_gc_count {
desc {
en: "GC the process after this many received messages."
zh: "在进程收到多少消息之后,对此进程执行垃圾回收"
}
label {
en: "Process GC messages num"
zh: "垃圾回收消息数"
}
}
force_gc_bytes {
desc {
en: "GC the process after specified number of bytes have passed through."
zh: "在进程处理过多少个字节之后,对此进程执行垃圾回收"
}
label {
en: "Process GC bytes"
zh: "垃圾回收字节数"
}
}
sysmon_vm_process_check_interval {
desc {
en: "The time interval for the periodic process limit check."
zh: "定期进程限制检查的时间间隔。"
}
label {
en: "Process limit check interval"
zh: "进程限制检查时间"
}
}
sysmon_vm_process_high_watermark {
desc {
en: "The threshold, as percentage of processes, for how many\n"
" processes can simultaneously exist at the local node before the corresponding\n"
" alarm is raised."
zh: "在发出相应警报之前,本地节点上可以同时存在多少进程的阈值(以进程百分比表示)。"
}
label {
en: "Process high watermark"
zh: "进程数高水位线"
}
}
sysmon_vm_process_low_watermark {
desc {
en: "The threshold, as percentage of processes, for how many\n"
" processes can simultaneously exist at the local node before the corresponding\n"
" alarm is cleared."
zh: "在清除相应警报之前,本地节点上可以同时存在多少进程的阈值(以进程百分比表示)。"
}
label {
en: "Process low watermark"
zh: "进程数低水位线"
}
}
sysmon_vm_long_gc {
desc {
en: "Enable Long GC monitoring."
zh: "启用长垃圾回收监控"
}
label {
en: "Enable Long GC monitoring."
zh: "启用长垃圾回收监控"
}
}
sysmon_vm_long_schedule {
desc {
en: "Enable Long Schedule monitoring."
zh: "启用长调度监控"
}
label {
en: "Enable Long Schedule monitoring."
zh: "启用长调度监控"
}
}
sysmon_vm_large_heap {
desc {
en: "Enable Large Heap monitoring."
zh: "启用大 heap 监控"
}
label {
en: "Enable Large Heap monitoring."
zh: "启用大 heap 监控"
}
}
sysmon_vm_busy_dist_port {
desc {
en: "Enable Busy Distribution Port monitoring."
zh: "启用分布式端口过忙监控"
}
label {
en: "Enable Busy Distribution Port monitoring."
zh: "启用分布式端口过忙监控"
}
}
sysmon_vm_busy_port {
desc {
en: "Enable Busy Port monitoring."
zh: "启用端口过忙监控"
}
label {
en: "Enable Busy Port monitoring."
zh: "启用端口过忙监控"
}
}
sysmon_os_cpu_check_interval {
desc {
en: "The time interval for the periodic CPU check."
zh: "定期 CPU 检查的时间间隔。"
}
label {
en: "The time interval for the periodic CPU check."
zh: "定期 CPU 检查的时间间隔"
}
}
sysmon_os_cpu_high_watermark {
desc {
en: "The threshold, as percentage of system CPU load,\n"
" for how much system cpu can be used before the corresponding alarm is raised."
zh: "在发出相应警报之前可以使用多少系统 CPU 的阈值以系统CPU负载的百分比表示。"
}
label {
en: "CPU high watermark"
zh: "CPU 高水位线"
}
}
sysmon_os_cpu_low_watermark {
desc {
en: "The threshold, as percentage of system CPU load,\n"
" for how much system cpu can be used before the corresponding alarm is cleared."
zh: "在解除相应警报之前可以使用多少系统 CPU 的阈值以系统CPU负载的百分比表示。"
}
label {
en: "CPU low watermark"
zh: "CPU 低水位线"
}
}
sysmon_os_mem_check_interval {
desc {
en: "The time interval for the periodic memory check."
zh: "定期内存检查的时间间隔。"
}
label {
en: "Mem check interval"
zh: "内存检查间隔"
}
}
sysmon_os_sysmem_high_watermark {
desc {
en: "The threshold, as percentage of system memory,\n"
" for how much system memory can be allocated before the corresponding alarm is raised."
zh: "在发出相应报警之前可以分配多少系统内存的阈值,以系统内存的百分比表示。"
}
label {
en: "SysMem high wartermark"
zh: "系统内存高水位线"
}
}
sysmon_os_procmem_high_watermark {
desc {
en: "The threshold, as percentage of system memory,\n"
" for how much system memory can be allocated by one Erlang process before\n"
" the corresponding alarm is raised."
zh: "在发出相应警报之前一个Erlang进程可以分配多少系统内存的阈值以系统内存的百分比表示。"
}
label {
en: "ProcMem high wartermark"
zh: "进程内存高水位线"
}
}
sysmon_top_num_items {
desc {
en: "The number of top processes per monitoring group"
zh: "每个监视组的顶级进程数"
}
label {
en: "Top num items"
zh: "顶级进程数"
}
}
sysmon_top_sample_interval {
desc {
en: "Specifies how often process top should be collected"
zh: "指定应收集进程顶部的频率"
}
label {
en: "Top sample interval"
zh: "取样时间"
}
}
sysmon_top_max_procs {
desc {
en: "Stop collecting data when the number of processes\n"
"in the VM exceeds this value"
zh: "当VM中的进程数超过此值时停止收集数据"
}
label {
en: "Max procs"
zh: "最大进程数"
}
}
sysmon_top_db_hostname {
desc {
en: "Hostname of the PostgreSQL database that collects the data points"
zh: "收集数据点的 PostgreSQL 数据库的主机名"
}
label {
en: "DB Hostname"
zh: "数据库主机名"
}
}
sysmon_top_db_port {
desc {
en: "Port of the PostgreSQL database that collects the data points"
zh: "收集数据点的 PostgreSQL 数据库的端口"
}
label {
en: "DB Port"
zh: "数据库端口"
}
}
sysmon_top_db_username {
desc {
en: "Username of the PostgreSQL database"
zh: "PostgreSQL 数据库的用户名"
}
label {
en: "DB Username"
zh: "数据库用户名"
}
}
sysmon_top_db_password {
desc {
en: "EMQX user password in the PostgreSQL database"
zh: "PostgreSQL 数据库的密码"
}
label {
en: "DB Password"
zh: "数据库密码"
}
}
sysmon_top_db_name {
desc {
en: "PostgreSQL database name"
zh: "PostgreSQL 数据库的数据库名"
}
label {
en: "DB Name"
zh: "数据库名"
}
}
alarm_actions {
desc {
en: "The actions triggered when the alarm is activated.<br/>\n"
"Currently, the following actions are supported: <code>log</code> and "
"<code>publish</code>.\n"
"<code>log</code> is to write the alarm to log (console or file).\n"
"<code>publish</code> is to publish the alarm as an MQTT message to "
"the system topics:\n"
"<code>$SYS/brokers/emqx@xx.xx.xx.x/alarms/activate</code> and\n"
"<code>$SYS/brokers/emqx@xx.xx.xx.x/alarms/deactivate</code>"
zh: "警报激活时触发的动作。<br/>\n"
"目前,支持以下操作:<code>log</code> 和 "
"<code>publish</code>.\n"
"<code>log</code> 将告警写入日志 (控制台或者文件).\n"
"<code>publish</code> 将告警作为 MQTT 消息发布到系统主题:\n"
"<code>$SYS/brokers/emqx@xx.xx.xx.x/alarms/activate</code> and\n"
"<code>$SYS/brokers/emqx@xx.xx.xx.x/alarms/deactivate</code>"
}
label: {
en: "Alarm Actions"
zh: "告警动作"
}
}
alarm_size_limit {
desc {
en: "The maximum total number of deactivated alarms to keep as history.<br>\n"
"When this limit is exceeded, the oldest deactivated alarms are "
"deleted to cap the total number.\n"
zh: "要保留为历史记录的已停用报警的最大总数。当超过此限制时,将删除最旧的停用报警,以限制总数。"
}
label: {
en: "Alarm size limit"
zh: "告警总数限制"
}
}
alarm_validity_period {
desc {
en: "Retention time of deactivated alarms. Alarms are not deleted immediately\n"
"when deactivated, but after the retention time.\n"
zh: "停用报警的保留时间。报警在停用时不会立即删除,而是在保留时间之后删除。"
}
label: {
en: "Alarm validity period"
zh: "告警保留时间"
}
}
flapping_detect_enable {
desc {
en: "Enable flapping connection detection feature."
zh: "启用抖动检测功能"
}
label: {
en: "Enable flapping detection"
zh: "启用抖动检测"
}
}
flapping_detect_max_count {
desc {
en: "The maximum number of disconnects allowed for a MQTT Client in `window_time`"
zh: "MQTT 客户端在\"窗口\"时间内允许的最大断开次数"
}
label: {
en: "Max count"
zh: "最大断开次数"
}
}
flapping_detect_window_time {
desc {
en: "The time window for flapping detection."
zh: "抖动检测的时间窗口。"
}
label: {
en: "Window time"
zh: "时间窗口"
}
}
flapping_detect_ban_time {
desc {
en: "How long the flapping clientid will be banned."
zh: "抖动的客户端将会被禁止登陆多长时间"
}
label: {
en: "Ban time"
zh: "禁止登陆时长"
}
}
persistent_session_store_enabled {
desc {
en: "Use the database to store information about persistent sessions.\n"
"This makes it possible to migrate a client connection to another\n"
"cluster node if a node is stopped.\n"
zh: "使用数据库存储有关持久会话的信息。\n"
"这使得在节点停止时,可以将客户端连接迁移到另一个群集节点。"
}
label: {
en: "Enable persistent session store"
zh: "启用持久会话保存"
}
}
persistent_session_store_storage_type {
desc {
en: "Store information about persistent sessions on disc or in ram.\n"
"If ram is chosen, all information about persistent sessions remains\n"
"as long as at least one node in a cluster is alive to keep the information.\n"
"If disc is chosen, the information is persisted on disc and will survive\n"
"cluster restart, at the price of more disc usage and less throughput.\n"
zh: "将有关持久会话的信息存储在磁盘或内存中。\n"
"如果选择了ram有关持久会话的所有信息将保留\n"
"只要群集中至少有一个节点处于活动状态,就可以保留信息。\n"
"如果选择了光盘,则信息将保留在光盘上,并且将继续存在\n"
"群集重新启动,代价是磁盘使用量增加,吞吐量降低。\n"
}
label: {
en: "Storage type"
zh: "存储类型"
}
}
persistent_session_store_max_retain_undelivered {
desc {
en: "The time messages that was not delivered to a persistent session\n"
"is stored before being garbage collected if the node the previous\n"
"session was handled on restarts of is stopped.\n"
zh: "如果重新启动时处理上一个会话的节点已停止,则未传递到持久会话的消息在垃圾收集之前会被存储。"
}
label: {
en: "Max retain undelivered"
zh: "未投递的消息保留条数"
}
}
persistent_session_store_message_gc_interval {
desc {
en: "The starting interval for garbage collection of undelivered messages to\n"
"a persistent session. This affects how often the \"max_retain_undelivered\"\n"
"is checked for removal.\n"
zh: "将未送达的消息垃圾收集到持久会话的开始间隔。\n"
"这会影响检查 \"max_retain_undelivered\"(最大保留未送达)的删除频率。"
}
label: {
en: "Message GC interval"
zh: "消息清理间隔"
}
}
persistent_session_store_session_message_gc_interval {
desc {
en: "The starting interval for garbage collection of transient data for\n"
"persistent session messages. This does not affect the lifetime length\n"
"of persistent session messages.\n"
zh: "持久会话消息的临时数据垃圾收集的开始间隔。\n"
"这不会影响持久会话消息的生命周期长度。\n"
}
label: {
en: "Session message GC interval"
zh: "会话消息清理间隔"
}
}
stats_enable {
desc {
en: "Enable/disable statistic data collection."
zh: "启用/禁用统计数据收集功能"
}
label: {
en: "Enable/disable statistic data collection."
zh: "启用/禁用统计数据收集功能"
}
}
zones {
desc {
en: """A zone is a set of configs grouped by the zone <code>name</code>.

View File

@ -239,10 +239,7 @@ fields("persistent_session_store") ->
boolean(),
#{
default => false,
desc =>
"Use the database to store information about persistent sessions.\n"
"This makes it possible to migrate a client connection to another\n"
"cluster node if a node is stopped.\n"
desc => ?DESC(persistent_session_store_enabled)
}
)},
{"storage_type",
@ -250,12 +247,7 @@ fields("persistent_session_store") ->
hoconsc:union([ram, disc]),
#{
default => disc,
desc =>
"Store information about persistent sessions on disc or in ram.\n"
"If ram is chosen, all information about persistent sessions remains\n"
"as long as at least one node in a cluster is alive to keep the information.\n"
"If disc is chosen, the information is persisted on disc and will survive\n"
"cluster restart, at the price of more disc usage and less throughput.\n"
desc => ?DESC(persistent_session_store_storage_type)
}
)},
{"max_retain_undelivered",
@ -263,10 +255,7 @@ fields("persistent_session_store") ->
duration(),
#{
default => "1h",
desc =>
"The time messages that was not delivered to a persistent session\n"
"is stored before being garbage collected if the node the previous\n"
"session was handled on restarts of is stopped.\n"
desc => ?DESC(persistent_session_store_max_retain_undelivered)
}
)},
{"message_gc_interval",
@ -274,10 +263,7 @@ fields("persistent_session_store") ->
duration(),
#{
default => "1h",
desc =>
"The starting interval for garbage collection of undelivered messages to\n"
"a persistent session. This affects how often the \"max_retain_undelivered\"\n"
"is checked for removal.\n"
desc => ?DESC(persistent_session_store_message_gc_interval)
}
)},
{"session_message_gc_interval",
@ -285,10 +271,7 @@ fields("persistent_session_store") ->
duration(),
#{
default => "1m",
desc =>
"The starting interval for garbage collection of transient data for\n"
"persistent session messages. This does not affect the lifetime length\n"
"of persistent session messages.\n"
desc => ?DESC(persistent_session_store_session_message_gc_interval)
}
)}
];
@ -299,7 +282,7 @@ fields("stats") ->
boolean(),
#{
default => true,
desc => "Enable/disable statistic data collection."
desc => ?DESC(stats_enable)
}
)}
];
@ -627,8 +610,7 @@ fields("flapping_detect") ->
boolean(),
#{
default => false,
desc =>
"Enable flapping connection detection feature."
desc => ?DESC(flapping_detect_enable)
}
)},
{"max_count",
@ -636,8 +618,7 @@ fields("flapping_detect") ->
integer(),
#{
default => 15,
desc =>
"The maximum number of disconnects allowed for a MQTT Client in `window_time`"
desc => ?DESC(flapping_detect_max_count)
}
)},
{"window_time",
@ -645,7 +626,7 @@ fields("flapping_detect") ->
duration(),
#{
default => "1m",
desc => "The time window for flapping detection."
desc => ?DESC(flapping_detect_window_time)
}
)},
{"ban_time",
@ -653,7 +634,7 @@ fields("flapping_detect") ->
duration(),
#{
default => "5m",
desc => "How long the flapping clientid will be banned."
desc => ?DESC(flapping_detect_ban_time)
}
)}
];
@ -664,7 +645,7 @@ fields("force_shutdown") ->
boolean(),
#{
default => true,
desc => "Enable `force_shutdown` feature."
desc => ?DESC(force_shutdown_enable)
}
)},
{"max_message_queue_len",
@ -672,7 +653,7 @@ fields("force_shutdown") ->
range(0, inf),
#{
default => 1000,
desc => "Maximum message queue length."
desc => ?DESC(force_shutdown_max_message_queue_len)
}
)},
{"max_heap_size",
@ -680,7 +661,7 @@ fields("force_shutdown") ->
wordsize(),
#{
default => "32MB",
desc => "Total heap size",
desc => ?DESC(force_shutdown_max_heap_size),
validator => fun ?MODULE:validate_heap_size/1
}
)}
@ -691,7 +672,7 @@ fields("overload_protection") ->
sc(
boolean(),
#{
desc => "React on system overload or not",
desc => ?DESC(overload_protection_enable),
default => false
}
)},
@ -699,9 +680,7 @@ fields("overload_protection") ->
sc(
range(0, inf),
#{
desc =>
"Some unimportant tasks could be delayed "
"for execution, here set the delays in ms",
desc => ?DESC(overload_protection_backoff_delay),
default => 1
}
)},
@ -709,7 +688,7 @@ fields("overload_protection") ->
sc(
boolean(),
#{
desc => "Skip forceful GC if necessary",
desc => ?DESC(overload_protection_backoff_gc),
default => false
}
)},
@ -717,7 +696,7 @@ fields("overload_protection") ->
sc(
boolean(),
#{
desc => "Skip process hibernation if necessary",
desc => ?DESC(overload_protection_backoff_hibernation),
default => true
}
)},
@ -725,7 +704,7 @@ fields("overload_protection") ->
sc(
boolean(),
#{
desc => "Close new incoming connections if necessary",
desc => ?DESC(overload_protection_backoff_new_conn),
default => true
}
)}
@ -737,7 +716,7 @@ fields("conn_congestion") ->
boolean(),
#{
default => false,
desc => "Enable or disable connection congestion alarm."
desc => ?DESC(conn_congestion_enable_alarm)
}
)},
{"min_alarm_sustain_duration",
@ -745,12 +724,7 @@ fields("conn_congestion") ->
duration(),
#{
default => "1m",
desc =>
"Minimal time before clearing the alarm.\n\n"
"The alarm is cleared only when there's no pending data in\n"
"the queue, and at least `min_alarm_sustain_duration`\n"
"milliseconds passed since the last time we considered the connection \"congested\".\n\n"
"This is to avoid clearing and raising the alarm again too often."
desc => ?DESC(conn_congestion_min_alarm_sustain_duration)
}
)}
];
@ -759,14 +733,14 @@ fields("force_gc") ->
{"enable",
sc(
boolean(),
#{default => true, desc => "Enable forced garbage collection."}
#{default => true, desc => ?DESC(force_gc_enable)}
)},
{"count",
sc(
range(0, inf),
#{
default => 16000,
desc => "GC the process after this many received messages."
desc => ?DESC(force_gc_count)
}
)},
{"bytes",
@ -774,7 +748,7 @@ fields("force_gc") ->
bytesize(),
#{
default => "16MB",
desc => "GC the process after specified number of bytes have passed through."
desc => ?DESC(force_gc_bytes)
}
)}
];
@ -1331,7 +1305,7 @@ fields("sysmon_vm") ->
duration(),
#{
default => "30s",
desc => "The time interval for the periodic process limit check."
desc => ?DESC(sysmon_vm_process_check_interval)
}
)},
{"process_high_watermark",
@ -1339,10 +1313,7 @@ fields("sysmon_vm") ->
percent(),
#{
default => "80%",
desc =>
"The threshold, as percentage of processes, for how many\n"
" processes can simultaneously exist at the local node before the corresponding\n"
" alarm is raised."
desc => ?DESC(sysmon_vm_process_high_watermark)
}
)},
{"process_low_watermark",
@ -1350,20 +1321,14 @@ fields("sysmon_vm") ->
percent(),
#{
default => "60%",
desc =>
"The threshold, as percentage of processes, for how many\n"
" processes can simultaneously exist at the local node before the corresponding\n"
" alarm is cleared."
desc => ?DESC(sysmon_vm_process_low_watermark)
}
)},
{"long_gc",
sc(
hoconsc:union([disabled, duration()]),
#{
desc =>
"Enable Long GC monitoring.<br/>\n"
"Notice: don't enable the monitor in production, because it adds overhead to\n"
" garbage collection."
desc => ?DESC(sysmon_vm_long_gc)
}
)},
{"long_schedule",
@ -1371,7 +1336,7 @@ fields("sysmon_vm") ->
hoconsc:union([disabled, duration()]),
#{
default => "240ms",
desc => "Enable Long Schedule monitoring."
desc => ?DESC(sysmon_vm_long_schedule)
}
)},
{"large_heap",
@ -1379,7 +1344,7 @@ fields("sysmon_vm") ->
hoconsc:union([disabled, bytesize()]),
#{
default => "32MB",
desc => "Enable Large Heap monitoring."
desc => ?DESC(sysmon_vm_large_heap)
}
)},
{"busy_dist_port",
@ -1387,7 +1352,7 @@ fields("sysmon_vm") ->
boolean(),
#{
default => true,
desc => "Enable Busy Distribution Port monitoring."
desc => ?DESC(sysmon_vm_busy_dist_port)
}
)},
{"busy_port",
@ -1395,7 +1360,7 @@ fields("sysmon_vm") ->
boolean(),
#{
default => true,
desc => "Enable Busy Port monitoring."
desc => ?DESC(sysmon_vm_busy_port)
}
)}
];
@ -1406,7 +1371,7 @@ fields("sysmon_os") ->
duration(),
#{
default => "60s",
desc => "The time interval for the periodic CPU check."
desc => ?DESC(sysmon_os_cpu_check_interval)
}
)},
{"cpu_high_watermark",
@ -1414,9 +1379,7 @@ fields("sysmon_os") ->
percent(),
#{
default => "80%",
desc =>
"The threshold, as percentage of system CPU load,\n"
" for how much system cpu can be used before the corresponding alarm is raised."
desc => ?DESC(sysmon_os_cpu_high_watermark)
}
)},
{"cpu_low_watermark",
@ -1424,9 +1387,7 @@ fields("sysmon_os") ->
percent(),
#{
default => "60%",
desc =>
"The threshold, as percentage of system CPU load,\n"
" for how much system cpu can be used before the corresponding alarm is cleared."
desc => ?DESC(sysmon_os_cpu_low_watermark)
}
)},
{"mem_check_interval",
@ -1434,7 +1395,7 @@ fields("sysmon_os") ->
hoconsc:union([disabled, duration()]),
#{
default => "60s",
desc => "The time interval for the periodic memory check."
desc => ?DESC(sysmon_os_mem_check_interval)
}
)},
{"sysmem_high_watermark",
@ -1442,9 +1403,7 @@ fields("sysmon_os") ->
percent(),
#{
default => "70%",
desc =>
"The threshold, as percentage of system memory,\n"
" for how much system memory can be allocated before the corresponding alarm is raised."
desc => ?DESC(sysmon_os_sysmem_high_watermark)
}
)},
{"procmem_high_watermark",
@ -1452,10 +1411,7 @@ fields("sysmon_os") ->
percent(),
#{
default => "5%",
desc =>
"The threshold, as percentage of system memory,\n"
" for how much system memory can be allocated by one Erlang process before\n"
" the corresponding alarm is raised."
desc => ?DESC(sysmon_os_procmem_high_watermark)
}
)}
];
@ -1467,7 +1423,7 @@ fields("sysmon_top") ->
#{
mapping => "system_monitor.top_num_items",
default => 10,
desc => "The number of top processes per monitoring group"
desc => ?DESC(sysmon_top_num_items)
}
)},
{"sample_interval",
@ -1476,7 +1432,7 @@ fields("sysmon_top") ->
#{
mapping => "system_monitor.top_sample_interval",
default => "2s",
desc => "Specifies how often process top should be collected"
desc => ?DESC(sysmon_top_sample_interval)
}
)},
{"max_procs",
@ -1485,9 +1441,7 @@ fields("sysmon_top") ->
#{
mapping => "system_monitor.top_max_procs",
default => 1_000_000,
desc =>
"Stop collecting data when the number of processes\n"
"in the VM exceeds this value"
desc => ?DESC(sysmon_top_max_procs)
}
)},
{"db_hostname",
@ -1495,7 +1449,7 @@ fields("sysmon_top") ->
string(),
#{
mapping => "system_monitor.db_hostname",
desc => "Hostname of the PostgreSQL database that collects the data points",
desc => ?DESC(sysmon_top_db_hostname),
default => ""
}
)},
@ -1505,7 +1459,7 @@ fields("sysmon_top") ->
#{
mapping => "system_monitor.db_port",
default => 5432,
desc => "Port of the PostgreSQL database that collects the data points"
desc => ?DESC(sysmon_top_db_port)
}
)},
{"db_username",
@ -1514,7 +1468,7 @@ fields("sysmon_top") ->
#{
mapping => "system_monitor.db_username",
default => "system_monitor",
desc => "EMQX username in the PostgreSQL database"
desc => ?DESC(sysmon_top_db_username)
}
)},
{"db_password",
@ -1523,7 +1477,7 @@ fields("sysmon_top") ->
#{
mapping => "system_monitor.db_password",
default => "system_monitor_password",
desc => "EMQX user password in the PostgreSQL database"
desc => ?DESC(sysmon_top_db_password)
}
)},
{"db_name",
@ -1532,7 +1486,7 @@ fields("sysmon_top") ->
#{
mapping => "system_monitor.db_name",
default => "postgres",
desc => "PostgreSQL database name"
desc => ?DESC(sysmon_top_db_name)
}
)}
];
@ -1545,15 +1499,7 @@ fields("alarm") ->
default => [log, publish],
validator => fun ?MODULE:validate_alarm_actions/1,
example => [log, publish],
desc =>
"The actions triggered when the alarm is activated.<br/>\n"
"Currently, the following actions are supported: <code>log</code> and "
"<code>publish</code>.\n"
"<code>log</code> is to write the alarm to log (console or file).\n"
"<code>publish</code> is to publish the alarm as an MQTT message to "
"the system topics:\n"
"<code>$SYS/brokers/emqx@xx.xx.xx.x/alarms/activate</code> and\n"
"<code>$SYS/brokers/emqx@xx.xx.xx.x/alarms/deactivate</code>"
desc => ?DESC(alarm_actions)
}
)},
{"size_limit",
@ -1562,10 +1508,7 @@ fields("alarm") ->
#{
default => 1000,
example => 1000,
desc =>
"The maximum total number of deactivated alarms to keep as history.<br>\n"
"When this limit is exceeded, the oldest deactivated alarms are "
"deleted to cap the total number.\n"
desc => ?DESC(alarm_size_limit)
}
)},
{"validity_period",
@ -1574,9 +1517,7 @@ fields("alarm") ->
#{
default => "24h",
example => "24h",
desc =>
"Retention time of deactivated alarms. Alarms are not deleted immediately\n"
"when deactivated, but after the retention time.\n"
desc => ?DESC(alarm_validity_period)
}
)}
];