Help us shape the future of Go! Take the 2026 Go Developer Survey

conditions

package
v0.0.15 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TypeReconciled                 = "Reconciled"
	TypeReady                      = "Ready"
	TypeError                      = "Error"
	ReasonReady                    = "Ready"
	ReasonReconciled               = "Ready"
	ReasonFailure                  = "Failure"
	ReasonUnsupportedConfiguration = "UnsupportedConfiguration"
)

Variables

This section is empty.

Functions

func ConditionReason

func ConditionReason[T GenericConditionType](object any, conditionType T) string

func ConditionStatus

func ConditionStatus[T GenericConditionType](object any, conditionType T) corev1.ConditionStatus

func FindDeploymentStatusCondition added in v0.0.10

func FindDeploymentStatusCondition(in *appsv1.Deployment, conditionType string) (appsv1.DeploymentCondition, bool)

func FindPodStatusCondition added in v0.0.10

func FindPodStatusCondition(in *corev1.Pod, conditionType string) (corev1.PodCondition, bool)

func Get

func Get(from Getter, t ConditionType) *metav1.Condition

Get returns the condition with the given type, if the condition does not exist, it returns nil.

Types

type ConditionType

type ConditionType string

ConditionType is a valid value for Condition.Type.

type Conditions

type Conditions []metav1.Condition

type GenericConditionType

type GenericConditionType interface {
	~string
}

type Getter

type Getter interface {
	metav1.Object
	runtime.Object

	// GetConditions returns the list of conditions for an object.
	GetConditions() Conditions
}

Getter interface defines methods that an object should implement in order to use the conditions package for getting conditions.

Jump to

Keyboard shortcuts

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