Documentation
¶
Index ¶
- Constants
- func RegisterPolicyEngine(name string, engine PolicyEngine) error
- type BaseDto
- type BasePolicy
- func (policy BasePolicy) CreateDefaultConfig(map[string]interface{}) interface{}
- func (policy BasePolicy) GetConfig(name, packageId string, zone *orm.GatewayZone, ctx map[string]interface{}) (PolicyDto, error)
- func (policy BasePolicy) GetName() string
- func (policy BasePolicy) MergeDiceConfig(map[string]interface{}) (PolicyDto, error)
- func (policy BasePolicy) NeedResetAnnotation(dto PolicyDto) bool
- func (policy BasePolicy) NeedSerialUpdate() bool
- func (policy BasePolicy) ParseConfig(interface{}, map[string]interface{}) (PolicyConfig, error)
- func (policy *BasePolicy) SetName(name string)
- func (policy BasePolicy) UnmarshalConfig([]byte) (interface{}, error, string)
- type IngressAnnotation
- type IngressController
- type PolicyConfig
- type PolicyDto
- type PolicyEngine
- type ServiceInfo
Constants ¶
View Source
const ( CTX_IDENTIFY = "id" CTX_K8S_CLIENT = "k8s_client" CTX_KONG_ADAPTER = "kong_adapter" CTX_ZONE = "zone" CTX_SERVICE_INFO = "service_info" )
Variables ¶
This section is empty.
Functions ¶
func RegisterPolicyEngine ¶
func RegisterPolicyEngine(name string, engine PolicyEngine) error
Types ¶
type BasePolicy ¶
type BasePolicy struct {
// contains filtered or unexported fields
}
func (BasePolicy) CreateDefaultConfig ¶
func (policy BasePolicy) CreateDefaultConfig(map[string]interface{}) interface{}
func (BasePolicy) GetConfig ¶
func (policy BasePolicy) GetConfig(name, packageId string, zone *orm.GatewayZone, ctx map[string]interface{}) (PolicyDto, error)
func (BasePolicy) GetName ¶
func (policy BasePolicy) GetName() string
func (BasePolicy) MergeDiceConfig ¶
func (policy BasePolicy) MergeDiceConfig(map[string]interface{}) (PolicyDto, error)
func (BasePolicy) NeedResetAnnotation ¶
func (policy BasePolicy) NeedResetAnnotation(dto PolicyDto) bool
func (BasePolicy) NeedSerialUpdate ¶
func (policy BasePolicy) NeedSerialUpdate() bool
func (BasePolicy) ParseConfig ¶
func (policy BasePolicy) ParseConfig(interface{}, map[string]interface{}) (PolicyConfig, error)
func (*BasePolicy) SetName ¶
func (policy *BasePolicy) SetName(name string)
func (BasePolicy) UnmarshalConfig ¶
func (policy BasePolicy) UnmarshalConfig([]byte) (interface{}, error, string)
type IngressAnnotation ¶
type IngressController ¶
type PolicyConfig ¶
type PolicyConfig struct {
KongPolicyChange bool
IngressAnnotation *IngressAnnotation
IngressController *IngressController
AnnotationReset bool
}
type PolicyEngine ¶
type PolicyEngine interface {
GetConfig(string, string, *orm.GatewayZone, map[string]interface{}) (PolicyDto, error)
MergeDiceConfig(map[string]interface{}) (PolicyDto, error)
CreateDefaultConfig(map[string]interface{}) PolicyDto
ParseConfig(PolicyDto, map[string]interface{}) (PolicyConfig, error)
NeedResetAnnotation(PolicyDto) bool
UnmarshalConfig([]byte) (PolicyDto, error, string)
SetName(name string)
GetName() string
NeedSerialUpdate() bool
}
func GetPolicyEngine ¶
func GetPolicyEngine(name string) (PolicyEngine, error)
type ServiceInfo ¶
Click to show internal directories.
Click to hide internal directories.