apis

package
v1.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 13, 2021 License: Apache-2.0 Imports: 5 Imported by: 12

Documentation

Index

Constants

View Source
const ReconcileError = "ReconcileError"
View Source
const ReconcileErrorReason = "LastReconcileCycleFailed"
View Source
const ReconcileSuccess = "ReconcileSuccess"
View Source
const ReconcileSuccessReason = "LastReconcileCycleSucceded"

Variables

This section is empty.

Functions

func AddOrReplaceCondition added in v1.0.0

func AddOrReplaceCondition(c metav1.Condition, conditions []metav1.Condition) []metav1.Condition

AddOrReplaceCondition adds or replaces the passed condition in the passed array of conditions

func GetCondition added in v1.0.1

func GetCondition(conditionType string, conditions []metav1.Condition) (metav1.Condition, bool)

GetCondition returns the condition with the given type, if it exists. If the condition does not exists it returns false.

func GetKeyLong added in v0.2.0

func GetKeyLong(obj metav1.Object) string

GetKeyLong return a unique key for a given object in the pattern of <kind>/<apiversion>/<namespace>/<name> namespace can be null

func GetKeyShort added in v0.2.0

func GetKeyShort(obj metav1.Object) string

GetKeyShort return a unique key for a given object in the pattern of <apiversion>/<namespace>/<name> namespace can be null

func GetLastCondition added in v1.0.1

func GetLastCondition(conditions []metav1.Condition) (metav1.Condition, bool)

GetLastCondition retruns the last condition based on the condition timestamp. if no condition is present it return false.

func IsErrorCondition added in v1.2.0

func IsErrorCondition(condition metav1.Condition) bool

Types

type ConditionsAware added in v1.0.0

type ConditionsAware interface {
	GetConditions() []metav1.Condition
	SetConditions(conditions []metav1.Condition)
}

ConditionsAware represents a CRD type that has been enabled with metav1.Conditions, it can then benefit of a series of utility methods.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL