Documentation ¶
Index ¶
- Constants
- func ActionFileCheck(conf ActionFile) error
- func ActionFileListCheck(actionList *ActionFileList) error
- func ErrorsActionsDo(req *bfe_basic.Request, actions []Action)
- func ErrorsConfCheck(conf ErrorsConfFile) error
- func ErrorsRuleCheck(conf ErrorsRuleFile) error
- func ProductRulesCheck(conf *ProductRulesFile) error
- func RuleListCheck(conf *RuleFileList) error
- type Action
- type ActionFile
- type ActionFileList
- type ConfModErrors
- type ErrorsConf
- type ErrorsConfFile
- type ErrorsRule
- type ErrorsRuleFile
- type ErrorsRuleTable
- type ModuleErrors
- type ProductRules
- type ProductRulesFile
- type RuleFileList
- type RuleList
Constants ¶
View Source
const ( RETURN = "RETURN" REDIRECT = "REDIRECT" )
View Source
const (
MaxPageSize = 2 * 1024 * 1024
)
Variables ¶
This section is empty.
Functions ¶
func ActionFileCheck ¶
func ActionFileCheck(conf ActionFile) error
ActionFileCheck check ActionFile, return nil if check ok
func ActionFileListCheck ¶
func ActionFileListCheck(actionList *ActionFileList) error
ActionFileListCheck check ActionFileList, return nil if check ok
func ErrorsActionsDo ¶
func ErrorsConfCheck ¶
func ErrorsConfCheck(conf ErrorsConfFile) error
ErrorsConfCheck check ErrorsConf
func ErrorsRuleCheck ¶
func ErrorsRuleCheck(conf ErrorsRuleFile) error
ErrorsRuleCheck check errors rule
func ProductRulesCheck ¶
func ProductRulesCheck(conf *ProductRulesFile) error
ProductRulesCheck check ProductRules
Types ¶
type ActionFile ¶
type ActionFileList ¶
type ActionFileList []ActionFile
type ConfModErrors ¶
type ConfModErrors struct { Basic struct { DataPath string // path of config data } Log struct { OpenDebug bool } }
func ConfLoad ¶
func ConfLoad(filePath string, confRoot string) (*ConfModErrors, error)
ConfLoad load config from config file
func (*ConfModErrors) Check ¶
func (cfg *ConfModErrors) Check(confRoot string) error
type ErrorsConf ¶
type ErrorsConf struct { Version string // version of the config Config ProductRules // product rules for errors }
func ErrorsConfLoad ¶
func ErrorsConfLoad(filename string) (ErrorsConf, error)
ErrorsConfLoad load errors config from file
type ErrorsConfFile ¶
type ErrorsConfFile struct { Version *string // version of the config Config *ProductRulesFile }
type ErrorsRule ¶
type ErrorsRuleFile ¶
type ErrorsRuleFile struct { Cond *string // condition for errors Actions *ActionFileList // list of actions }
type ErrorsRuleTable ¶
type ErrorsRuleTable struct {
// contains filtered or unexported fields
}
func NewErrorsRuleTable ¶
func NewErrorsRuleTable() *ErrorsRuleTable
func (*ErrorsRuleTable) Search ¶
func (t *ErrorsRuleTable) Search(product string) (*RuleList, bool)
Search find rules for given product
func (*ErrorsRuleTable) Update ¶
func (t *ErrorsRuleTable) Update(conf ErrorsConf)
type ModuleErrors ¶
type ModuleErrors struct {
// contains filtered or unexported fields
}
func NewModuleErrors ¶
func NewModuleErrors() *ModuleErrors
func (*ModuleErrors) Init ¶
func (m *ModuleErrors) Init(cbs *bfe_module.BfeCallbacks, whs *web_monitor.WebHandlers, cr string) error
func (*ModuleErrors) Name ¶
func (m *ModuleErrors) Name() string
type ProductRules ¶
type ProductRulesFile ¶
type ProductRulesFile map[string]*RuleFileList // product => list of errors rules
type RuleFileList ¶
type RuleFileList []ErrorsRuleFile
type RuleList ¶
type RuleList []ErrorsRule
Click to show internal directories.
Click to hide internal directories.