conditions

package
v2.24.1 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package conditions provides utilities for manipulating the status conditions of Kubernetes resource objects that implement the Getter and/or Setter interfaces.

Usage of this package within GitOps Toolkit components working with conditions is RECOMMENDED, as it provides a wide range of helpers to work around common reconciler problems, like setting a Condition status based on a summarization of other conditions, producing an aggregate Condition based on the conditions of a list of Kubernetes resources objects, recognition of negative polarity or "abnormal-true" conditions, etc.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

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

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

func UnknownCondition

func UnknownCondition(t, reason, messageFormat string, messageArgs ...interface{}) *metav1.Condition

UnknownCondition returns a condition with Status=Unknown and the given type, reason and message.

Types

type Getter

type Getter interface {
	client.Object
	meta.ObjectWithConditions
}

Getter interface defines methods that a Kubernetes resource 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