feat(notify): 告警补服务端掉线/Agent 不可达/配置漂移,巡检改 Source 接口(v1.2.10)
- 三个新事件(默认关闭):公网服务端掉线、公网 agent 不可达、配置漂移;连续失败阈值与漂移提醒间隔均可配,达标与恢复各报一次 - 避免误报:只在「用户要服务端运行」时判定掉线;ConnectionState=unknown 按健康处理;没配 agent 的服务端不参与可达性判定 - internal/monitor 改 Source 接口(Routes/Servers/Agents/Drift),frp 适配在 internal/app/monitor_source.go;「连续 N 次」抽成共用 failureTransition,通知一律在锁外调用 - 通知图标分类补齐;通知方式标签改「Webhook / IM 机器人」;新增 6 个设置项;补 serverDown/serverLabel/stateOr 测试 - agent 无改动,AgentVersion 保持 0.12.2
This commit is contained in:
@@ -46,6 +46,12 @@ const (
|
||||
KeyNotifyMemoryThreshold = "notify_memory_threshold"
|
||||
KeyNotifyDiskThreshold = "notify_disk_threshold"
|
||||
KeyNotifyTunnelFailThreshold = "notify_tunnel_fail_threshold"
|
||||
KeyNotifyOnFrpsDown = "notify_on_frps_down"
|
||||
KeyNotifyOnAgentUnreachable = "notify_on_agent_unreachable"
|
||||
KeyNotifyOnRouteDrift = "notify_on_route_drift"
|
||||
KeyNotifyFrpsFailThreshold = "notify_frps_fail_threshold"
|
||||
KeyNotifyAgentFailThreshold = "notify_agent_fail_threshold"
|
||||
KeyNotifyDriftCooldownHours = "notify_drift_cooldown_hours"
|
||||
KeyTrustedProxy = "trusted_proxy_json"
|
||||
KeyGlobalIPBlacklist = "global_ip_blacklist"
|
||||
KeyGlobalIPWhitelist = "global_ip_whitelist"
|
||||
|
||||
Reference in New Issue
Block a user