Documentation ¶
Index ¶
- Constants
- Variables
- func AddNewWarningConfig(p WaringConfig) (string, error)
- func AppendWarning(data WarningContent)
- func CheckWarngConfigBySendTest(config WaringConfig, c string) error
- func DelWarningConfig(ID int) error
- func GetWarningConfigList() map[string]WaringConfig
- func InitWarningConfigCache()
- func Register(name string, f WarningFunInterface)
- type Email
- type EmailParam
- type WaringConfig
- type WarningContent
- type WarningFunInterface
- type WarningType
- type WeChatWorkParam
- type WechatWork
Constants ¶
View Source
const WARNING_KEY_PREFIX = "bifrost_warning_config_"
Variables ¶
View Source
var IP string = ""
View Source
var WarningChan chan WarningContent
Functions ¶
func AddNewWarningConfig ¶
func AddNewWarningConfig(p WaringConfig) (string, error)
func CheckWarngConfigBySendTest ¶
func CheckWarngConfigBySendTest(config WaringConfig, c string) error
func DelWarningConfig ¶
func GetWarningConfigList ¶
func GetWarningConfigList() map[string]WaringConfig
func InitWarningConfigCache ¶
func InitWarningConfigCache()
func Register ¶
func Register(name string, f WarningFunInterface)
Types ¶
type EmailParam ¶
type WaringConfig ¶
type WarningContent ¶
type WarningFunInterface ¶
type WarningType ¶
type WarningType string
const ( WARNINGERROR WarningType = "ERROR" WARNINGNORMAL WarningType = "NORMAL" )
type WeChatWorkParam ¶
type WechatWork ¶
type WechatWork struct {
// contains filtered or unexported fields
}
func (*WechatWork) SendWarning ¶
func (This *WechatWork) SendWarning(p map[string]interface{}, title string, Body string) error
Click to show internal directories.
Click to hide internal directories.