路由规则可以单独设置UAM(仅企业版可用)

This commit is contained in:
GoEdgeLab
2022-05-04 20:32:03 +08:00
parent e36027c3b3
commit 6a015b7afe
4 changed files with 505 additions and 181 deletions
+11
View File
@@ -46,6 +46,9 @@ type HTTPWebConfig struct {
RequestLimit *HTTPRequestLimitConfig `yaml:"requestLimit" json:"requestLimit"` // 并发请求限制
RequestScripts *HTTPRequestScriptsConfig `yaml:"requestScripts" json:"requestScripts"` // HTTP请求相关脚本
// UAM
UAM *UAMConfig `yaml:"uam" json:"uam"`
}
func (this *HTTPWebConfig) Init() error {
@@ -271,6 +274,14 @@ func (this *HTTPWebConfig) Init() error {
}
}
// uam
if this.UAM != nil {
err := this.UAM.Init()
if err != nil {
return err
}
}
return nil
}
+2 -1
View File
@@ -3,7 +3,8 @@
package serverconfigs
type UAMConfig struct {
IsOn bool `yaml:"isOn" json:"isOn"`
IsPrior bool `yaml:"isPrior" json:"isPrior"`
IsOn bool `yaml:"isOn" json:"isOn"`
}
func (this *UAMConfig) Init() error {