Documentation ¶
Index ¶
- Constants
- func AsTypedError[T error](err error) (T, bool)
- func NewNotOwnedError(namespace string, name string, gvk schema.GroupVersionKind, sourceName string, ...) error
- type CloudErrorDetails
- type ConfigMapNotFound
- type DestinationExpression
- type ErrorClassification
- type NotOwnedError
- type ReferenceNotFound
- type SecretNotFound
- type SubscriptionMismatch
Constants ¶
const ( ErrorRetryable = ErrorClassification("retryable") ErrorFatal = ErrorClassification("fatal") )
const ( UnknownErrorCode = "UnknownError" UnknownErrorMessage = "There was an unknown deployment error" )
Variables ¶
This section is empty.
Functions ¶
func AsTypedError ¶
func NewNotOwnedError ¶
func NewNotOwnedError(namespace string, name string, gvk schema.GroupVersionKind, sourceName string, sourceGvk schema.GroupVersionKind) error
Types ¶
type CloudErrorDetails ¶
type CloudErrorDetails struct { Classification ErrorClassification Code string Message string }
type ConfigMapNotFound ¶
type ConfigMapNotFound struct { NamespacedName types.NamespacedName // contains filtered or unexported fields }
ConfigMapNotFound error is used when configmap or its expected keys are not found
func NewConfigMapNotFoundError ¶
func NewConfigMapNotFoundError(name types.NamespacedName, cause error) *ConfigMapNotFound
func (*ConfigMapNotFound) Cause ¶
func (e *ConfigMapNotFound) Cause() error
func (*ConfigMapNotFound) Error ¶
func (e *ConfigMapNotFound) Error() string
func (*ConfigMapNotFound) Is ¶
func (e *ConfigMapNotFound) Is(err error) bool
type DestinationExpression ¶ added in v2.10.0
type DestinationExpression struct { // Name is the name of the Kubernetes configmap or secret to write to. // The configmap or secret will be created in the same namespace as the resource. // +kubebuilder:validation:Required Name string `json:"name,omitempty"` // Key is the key in the ConfigMap or Secret being written to. If the CEL expression in Value returns a string // this is required to identify what key to write to. If the CEL expression in Value returns a map[string]string // Key must not be set, instead the keys written will be determined dynamically based on the keys of the resulting // map[string]string. Key string `json:"key,omitempty"` // Value is a CEL expression. The CEL expression may return a string or a map[string]string. For more information see TODO (improve this) // +kubebuilder:validation:Required Value string `json:"value,omitempty"` }
DestinationExpression is a CEL expression and a destination to store the result in. The destination may be a secret or a configmap. The value of the expression is stored at the specified location in the destination. +kubebuilder:object:generate=true
func (*DestinationExpression) DeepCopy ¶ added in v2.10.0
func (in *DestinationExpression) DeepCopy() *DestinationExpression
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DestinationExpression.
func (*DestinationExpression) DeepCopyInto ¶ added in v2.10.0
func (in *DestinationExpression) DeepCopyInto(out *DestinationExpression)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (DestinationExpression) String ¶ added in v2.10.0
func (s DestinationExpression) String() string
type ErrorClassification ¶
type ErrorClassification string
type NotOwnedError ¶
type NotOwnedError struct { Namespace string TargetName string TargetType string SourceName string SourceType string }
NotOwnedError indicates the target resource is not owned by the resource attempting to write it
func AsNotOwnedError ¶
func AsNotOwnedError(err error) (*NotOwnedError, bool)
func (*NotOwnedError) Error ¶
func (e *NotOwnedError) Error() string
type ReferenceNotFound ¶
type ReferenceNotFound struct { NamespacedName types.NamespacedName // contains filtered or unexported fields }
func NewReferenceNotFoundError ¶
func NewReferenceNotFoundError(name types.NamespacedName, cause error) *ReferenceNotFound
func (*ReferenceNotFound) Cause ¶
func (e *ReferenceNotFound) Cause() error
func (*ReferenceNotFound) Error ¶
func (e *ReferenceNotFound) Error() string
func (*ReferenceNotFound) Is ¶
func (e *ReferenceNotFound) Is(err error) bool
type SecretNotFound ¶
type SecretNotFound struct { NamespacedName types.NamespacedName // contains filtered or unexported fields }
SecretNotFound error is used when secret or its expected keys are not found
func NewSecretNotFoundError ¶
func NewSecretNotFoundError(name types.NamespacedName, cause error) *SecretNotFound
func (*SecretNotFound) Cause ¶
func (e *SecretNotFound) Cause() error
func (*SecretNotFound) Error ¶
func (e *SecretNotFound) Error() string
func (*SecretNotFound) Is ¶
func (e *SecretNotFound) Is(err error) bool
type SubscriptionMismatch ¶ added in v2.3.0
type SubscriptionMismatch struct { ExpectedSubscription string ActualSubscription string // contains filtered or unexported fields }
SubscriptionMismatch error is used when a child resource and parent resource subscription don't match
func NewSubscriptionMismatchError ¶ added in v2.3.0
func NewSubscriptionMismatchError(expectedSub string, actualSub string) *SubscriptionMismatch
func (*SubscriptionMismatch) Cause ¶ added in v2.3.0
func (e *SubscriptionMismatch) Cause() error
func (*SubscriptionMismatch) Error ¶ added in v2.3.0
func (e *SubscriptionMismatch) Error() string
func (*SubscriptionMismatch) Format ¶ added in v2.3.0
func (e *SubscriptionMismatch) Format(s fmt.State, verb rune)
func (*SubscriptionMismatch) Is ¶ added in v2.3.0
func (e *SubscriptionMismatch) Is(err error) bool