Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client interface {
// Run executes the EC2 API poller. It will update the instance cache
// periodically.
Run(context.Context) error
// List returns all EC2 Instances that are currently in the cache. Those
// instance cache will be updated in the background.
List(context.Context) []Pod
// SignalEmitter gets triggered every time the cache changes. See syncutil
// package for more information.
SignalEmitter() *syncutil.SignalEmitter
// Healthy indicates whether the background job is running correctly.
Healthy() bool
// Evict deletes a pod.
Evict(context.Context, *Pod) error
}
func New ¶
func New(kube kubernetes.Interface) Client
type OwnerReadyReason ¶
type OwnerReadyReason struct {
CanDecrement bool `logfield:"pod-owner-ready-can-decrement"`
Short string `logfield:"pod-owner-ready-short"`
Reason string `logfield:"-"`
}
func GetOwnerReadyFromReplicas ¶
func GetOwnerReadyFromReplicas(kind string, specReplicas *int32, haveReplicas int32) OwnerReadyReason
func GetOwnerReadyStatic ¶
func GetOwnerReadyStatic(kind string) *OwnerReadyReason
type PDBReadyReason ¶ added in v2.6.0
type Pod ¶
type Pod struct {
Name string `logfield:"pod-name"`
Namespace string `logfield:"pod-namespace"`
NodeName string `logfield:"node-name"`
AppName string `logfield:"app-name"`
AppInstance string `logfield:"app-instance"`
AppVersion string `logfield:"app-version"`
AppComponent string `logfield:"app-component"`
OwnerKind string `logfield:"pod-owner-kind"`
OwnerName string `logfield:"pod-owner-name"`
OwnerReady OwnerReadyReason `logfield:",squash"`
PDBReady PDBReadyReason `logfield:",squash"`
CreatedTime time.Time `logfield:"pod-created-time"`
}
func (*Pod) ImmuneToEviction ¶
Click to show internal directories.
Click to hide internal directories.