Documentation
¶
Index ¶
- Variables
- func GetNestedValue(m map[string]any, path ...string) (any, error)
- func IsCRDNotFound(err error) bool
- func IsManaged() client.MatchingLabels
- func MustMarshal(v any) []byte
- func SetLabel(obj v1.Object, label string, value string)
- func SetManagedBy(obj v1.Object)
- func SetNestedDefault(m map[string]any, v any, path ...string) error
- func UpdateConditions(conditions *[]metav1.Condition, newConditions []metav1.Condition) bool
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func GetNestedValue ¶
GetNestedValue traverses a map and looks for a value under the given path. If the value was not found, `ErrValueNotFound` will be returned.
func IsCRDNotFound ¶
IsCRDNotFound checks if the given error is a CRD not found error.
func IsManaged ¶
func IsManaged() client.MatchingLabels
func MustMarshal ¶
MustMarshal returns the JSON encoding of v and panics if there is an error.
func SetManagedBy ¶
func SetNestedDefault ¶
SetNestedDefault traverses a map and sets a default value if no map entry exists yet under the given key.
func UpdateConditions ¶
UpdateConditions merges the "newConditions" into "conditions" while keeping the "LastTransitionTime" of unchanged conditions and removing stale conditions that are not present in "newConditions" anymore.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.