Documentation ¶
Index ¶
Constants ¶
const (
Namespace = "d8-upmeter"
)
Variables ¶
var ( // ErrSkip is the legal abortion of scheduling ErrSkip = fmt.Errorf("scheduling skipped") )
Functions ¶
This section is empty.
Types ¶
type Cleaner ¶
func NewCleaner ¶
func NewCleaner(patcher *object_patch.PatchCollector, logger *logrus.Entry, pods []snapshot.Pod) Cleaner
type IndexSelector ¶
type IndexSelectorPipe ¶
type IndexSelectorPipe []IndexSelector
IndexSelectorPipe is the sequential wrapper for other sts selectors. The result is returned from the first successful selection or abortion error. Selection is ignored on next error.
func NewStatefulSetSelector ¶
func NewStatefulSetSelector( nodes []snapshot.Node, storageClass string, pvcs []snapshot.PvcTermination, pods []snapshot.Pod, disruptionAllowed bool, ) IndexSelectorPipe
NewStatefulSetSelector creates statefulset choosing pipeline. The result returns ffrom the first successful selection. If no selection occurs, the pipeline returns ErrSkip.
type NodeFilterPipe ¶
type NodeFilterPipe []NodeFilter
NodeFilterPipe is the sequential wrapper for other node filters. A result of each filter is passed to the next one. The filters do not share knowledge about each other. Filters are responsible to handle empty input their own way.
func NewNodeSelector ¶
func NewNodeSelector(state State) NodeFilterPipe
NewNodeSelector crates the node fuiltering pipeline. The resulting node list is the result of all filters in the sequence from top to bottom.
type Scheduler ¶
type Scheduler struct {
// contains filtered or unexported fields
}
func New ¶
func New(indexSelector IndexSelector, nodeFilter NodeFilter, cleaner Cleaner, image, storageClass string) *Scheduler