Documentation ¶
Index ¶
- Constants
- Variables
- func GetPodsState(podList *apicorev1.PodList) shared.State
- func IsStatefulSetReady(statefulSet *apiappsv1.StatefulSet) bool
- type DeploymentStateCheck
- type DeploymentStateChecker
- type Manager
- type ManagerKind
- type ManagerStateCheck
- type StatefulSetStateCheck
- type StatefulSetStateChecker
Constants ¶
View Source
const ( NewReplicaSetAvailableReason = "NewReplicaSetAvailable" FoundNewReplicaSetReason = "FoundNewReplicaSet" NewReplicaSetCreatedReason = "NewReplicaSetCreated" ReplicaSetUpdatedReason = "ReplicaSetUpdated" )
Variables ¶
View Source
var ( ErrNoManagerProvided = errors.New("failed to find manager in provided resources") ErrNoStateDetermined = errors.New("failed to determine state for manager") )
Functions ¶
func IsStatefulSetReady ¶
func IsStatefulSetReady(statefulSet *apiappsv1.StatefulSet) bool
Types ¶
type DeploymentStateCheck ¶
type DeploymentStateCheck struct{}
func NewDeploymentStateCheck ¶
func NewDeploymentStateCheck() *DeploymentStateCheck
func (*DeploymentStateCheck) GetState ¶
func (*DeploymentStateCheck) GetState( deploy *apiappsv1.Deployment, ) (shared.State, error)
type DeploymentStateChecker ¶
type DeploymentStateChecker interface {
GetState(deploy *apiappsv1.Deployment) (shared.State, error)
}
type ManagerKind ¶
type ManagerKind string
const ( DeploymentKind ManagerKind = "Deployment" StatefulSetKind ManagerKind = "StatefulSet" )
type ManagerStateCheck ¶
type ManagerStateCheck struct {
// contains filtered or unexported fields
}
func NewManagerStateCheck ¶
func NewManagerStateCheck(statefulSetChecker StatefulSetStateChecker, deploymentChecker DeploymentStateChecker, ) *ManagerStateCheck
func (*ManagerStateCheck) GetState ¶
func (m *ManagerStateCheck) GetState(ctx context.Context, clnt client.Client, resources []*resource.Info, ) (shared.State, error)
Determines the state based on the manager. The manager may either be a Deployment or a StatefulSet and must be included in the provided resources. Will be refactored with https://github.com/kyma-project/lifecycle-manager/issues/1831
type StatefulSetStateCheck ¶
type StatefulSetStateCheck struct{}
func NewStatefulSetStateCheck ¶
func NewStatefulSetStateCheck() *StatefulSetStateCheck
Click to show internal directories.
Click to hide internal directories.