condition

package
v0.8.4 Latest Latest
Warning

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

Go to latest
Published: May 9, 2022 License: Apache-2.0, MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder interface {
	WithOldConditions(conditions []druidv1alpha1.Condition) Builder
	WithResults(result []Result) Builder
	WithNowFunc(now func() metav1.Time) Builder
	Build() []druidv1alpha1.Condition
}

Builder is an interface for building conditions.

func NewBuilder

func NewBuilder() Builder

NewBuilder returns a Builder for a specific condition.

type Checker

type Checker interface {
	Check(status druidv1alpha1.EtcdStatus) Result
}

Checker is an interface to check the etcd resource and to return condition results.

func AllMembersCheck

func AllMembersCheck() Checker

AllMembersCheck returns a check for the "AllMembersReady" condition.

func ReadyCheck

func ReadyCheck() Checker

ReadyCheck returns a check for the "Ready" condition.

type Result

type Result interface {
	ConditionType() druidv1alpha1.ConditionType
	Status() druidv1alpha1.ConditionStatus
	Reason() string
	Message() string
}

Jump to

Keyboard shortcuts

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