Documentation ¶
Overview ¶
Package shadowpod contains the validating webhook logic and the cache of peering information.
Index ¶
- type Description
- type Validator
- func (spv *Validator) CacheRefresher(interval time.Duration) func(ctx context.Context) error
- func (spv *Validator) DecodeShadowPod(obj runtime.RawExtension) (shadowpod *vkv1alpha1.ShadowPod, err error)
- func (spv *Validator) Handle(ctx context.Context, req admission.Request) admission.Response
- func (spv *Validator) HandleCreate(ctx context.Context, req *admission.Request) admission.Response
- func (spv *Validator) HandleDelete(ctx context.Context, req *admission.Request) admission.Response
- func (spv *Validator) HandleUpdate(ctx context.Context, req *admission.Request) admission.Response
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Description ¶
type Description struct {
// contains filtered or unexported fields
}
Description is a struct that contains the main informations about a shadow pod.
type Validator ¶
type Validator struct { PeeringCache *peeringCache // contains filtered or unexported fields }
Validator is the handler used by the Validating Webhook to validate shadow pods.
func NewValidator ¶
NewValidator creates a new shadow pod validator.
func (*Validator) CacheRefresher ¶
CacheRefresher is a wrapper function that receives a ShadowPodValidator and starts a PollImmediateInfinite timer to periodically refresh the cache.
func (*Validator) DecodeShadowPod ¶
func (spv *Validator) DecodeShadowPod(obj runtime.RawExtension) (shadowpod *vkv1alpha1.ShadowPod, err error)
DecodeShadowPod decodes a shadow pod from a given runtime object.
func (*Validator) Handle ¶
Handle is the function in charge of handling the webhook validation request about the creation, update and deletion of shadowpods.
func (*Validator) HandleCreate ¶
HandleCreate is the function in charge of handling Creation requests.
func (*Validator) HandleDelete ¶
HandleDelete is the function in charge of handling Deletion requests.