Documentation ¶
Index ¶
- type Policy
- func (policy Policy) CreateDefaultConfig(gatewayProvider string, ctx map[string]interface{}) apipolicy.PolicyDto
- func (policy Policy) ParseConfig(dto apipolicy.PolicyDto, ctx map[string]interface{}, forValidate bool) (apipolicy.PolicyConfig, error)
- func (policy Policy) UnmarshalConfig(config []byte, gatewayProvider string) (apipolicy.PolicyDto, error, string)
- type PolicyDto
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Policy ¶
type Policy struct {
apipolicy.BasePolicy
}
func (Policy) CreateDefaultConfig ¶
func (Policy) ParseConfig ¶
func (policy Policy) ParseConfig(dto apipolicy.PolicyDto, ctx map[string]interface{}, forValidate bool) (apipolicy.PolicyConfig, error)
forValidate 用于识别解析的目的,如果解析是用来做 nginx 配置冲突相关的校验,则关于数据表、调用 kong 接口的操作都不会执行
type PolicyDto ¶
type PolicyDto struct { apipolicy.BaseDto ReqBuffer bool `json:"reqBuffer"` RespBuffer bool `json:"respBuffer"` ClientReqLimit int64 `json:"clientReqLimit"` ClientReqTimeout int64 `json:"clientReqTimeout"` ClientRespTimeout int64 `json:"clientRespTimeout"` ProxyReqTimeout int64 `json:"proxyReqTimeout"` ProxyRespTimeout int64 `json:"proxyRespTimeout"` HostPassthrough bool `json:"hostPassthrough"` SSLRedirect bool `json:"sslRedirect"` }
Click to show internal directories.
Click to hide internal directories.