v1

package
v0.0.0-...-9632032 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2019 License: Apache-2.0 Imports: 3 Imported by: 18

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckIfConditionChanged

func CheckIfConditionChanged(currentCond, newCond *Condition) bool

func PrepareCondition

func PrepareCondition(currentConditions []Condition, newCondition *Condition) bool

Types

type Condition

type Condition struct {
	// Type of State condition.
	Type ConditionType `json:"type"`
	// Status of the condition.
	Status ConditionStatus `json:"status"`
	// Last time the condition transitioned from one status to another.
	LastTransitionTime meta_v1.Time `json:"lastTransitionTime,omitempty"`
	// The reason for the condition's last transition.
	Reason string `json:"reason,omitempty"`
	// A human readable message indicating details about the transition.
	Message string `json:"message,omitempty"`
}

+k8s:deepcopy-gen=true Condition describes the state of an object at a certain point.

func FindCondition

func FindCondition(conditions []Condition, conditionType ConditionType) (int, *Condition)

func (*Condition) DeepCopy

func (in *Condition) DeepCopy() *Condition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Condition.

func (*Condition) DeepCopyInto

func (in *Condition) DeepCopyInto(out *Condition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Condition) String

func (c *Condition) String() string

type ConditionStatus

type ConditionStatus string
const (
	ConditionTrue    ConditionStatus = "True"
	ConditionFalse   ConditionStatus = "False"
	ConditionUnknown ConditionStatus = "Unknown"
)

These are some possible condition statuses. "ConditionTrue" means a resource is in the condition. "ConditionFalse" means a resource is not in the condition. "ConditionUnknown" means kubernetes can't decide if a resource is in the condition or not. In the future, we could add other intermediate conditions, e.g. ConditionDegraded.

type ConditionType

type ConditionType string
const (
	ConditionInProgress ConditionType = "InProgress"
	ConditionReady      ConditionType = "Ready"
	ConditionError      ConditionType = "Error"
)

These are some possible conditions of an object.

Jump to

Keyboard shortcuts

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