Documentation
¶
Index ¶
Constants ¶
View Source
const ( // RedisPrefix 参数:business。参数1:bid;参数2:监控ID RedisPrefix = "monitor_stats_%d" // CompGT 大于 CompGT = ">" // CompLT 小于 CompLT = "<" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Rule ¶
type Rule struct { ID int64 `json:"id"` Type int8 `json:"type"` BID int8 `json:"bid"` Name string `json:"name"` State int8 `json:"state"` STime string `json:"stime"` ETime string `json:"etime"` CTime string `json:"ctime"` MTime string `json:"mtime"` UID int64 `json:"uid"` RuleConf *RuleConf `json:"rule"` }
Rule 监控规则信息
type RuleConf ¶
type RuleConf struct { Name string `json:"name"` MoniCdt map[string]struct { Comp string `json:"comparison"` Value int64 `json:"value"` } `json:"moni_cdt"` NotifyCdt map[string]struct { Comp string `json:"comparison"` Value int64 `json:"value"` } `json:"notify_cdt"` Notify struct { Way int8 `json:"way"` Member []string `json:"member"` } `json:"notify"` }
RuleConf 监控方案配置结构体
type RuleResultData ¶
type RuleResultData struct { Rule *Rule `json:"rule"` User *User `json:"user"` Stats *Stats `json:"stats"` }
RuleResultData 返回的结果数据
Click to show internal directories.
Click to hide internal directories.