Documentation ¶
Overview ¶
Package kfvalidation contains validation webhook callbacks for Kf components that require cross-component lookups.
These webhooks shouldn't be the _only_ thing protecting invalid state, instead, they should be used to provide better UX by failing commands fast.
Index ¶
- func AppValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
- func ClusterServiceBrokerValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
- func RouteValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
- func ServiceBrokerValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
- func ServiceInstanceBindingValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
- func ServiceInstanceValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
- type AppInformerKey
- type ServiceInstanceBindingInformerKey
- type ServiceInstanceInformerKey
- type SpaceInformerKey
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AppValidationCallback ¶
func AppValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
AppValidationCallback is executed to validate App info that requires runtime lookups.
func ClusterServiceBrokerValidationCallback ¶
func ClusterServiceBrokerValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
ClusterServiceBrokerValidationCallback validates that an existing ServiceBroker is not part of a ClusterServiceInstance. It is intended to be used as a callback on a delete request.
func RouteValidationCallback ¶
func RouteValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
RouteValidationCallback is executed to validate Route info that requires runtime lookups.
func ServiceBrokerValidationCallback ¶
func ServiceBrokerValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
ServiceBrokerValidationCallback validates that an existing ServiceBroker is not part of a ServiceInstance. It is intended to be used as a callback on a delete request.
func ServiceInstanceBindingValidationCallback ¶
func ServiceInstanceBindingValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
ServiceInstanceBindingValidationCallback validates that the App and ServiceInstance referenced in a ServiceInstanceBinding exist. It is intended to be used as a callback on create and update requests.
func ServiceInstanceValidationCallback ¶
func ServiceInstanceValidationCallback(ctx context.Context, unstructured *unstructured.Unstructured) error
ServiceInstanceValidationCallback validates that an existing ServiceInstance is not part of a binding. It is intended to be used as a callback on a delete request.
Types ¶
type AppInformerKey ¶
type AppInformerKey struct{}
AppInformerKey is used for associating the AppInformer inside the context.Context.
type ServiceInstanceBindingInformerKey ¶
type ServiceInstanceBindingInformerKey struct{}
ServiceInstanceBindingInformerKey is used for associating the ServiceInstanceBindingInformer inside the context.Context.
type ServiceInstanceInformerKey ¶
type ServiceInstanceInformerKey struct{}
ServiceInstanceInformerKey is used for associating the ServiceInstanceInformer inside the context.Context.
type SpaceInformerKey ¶
type SpaceInformerKey struct{}
SpaceInformerKey is used for associating the SpaceInformer inside the context.Context.