scheduler

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Apr 20, 2021 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Failover bool

Failover indicates if the scheduler should performs re-scheduler in case of cluster failure. TODO(RainbowMango): Remove the temporary solution by introducing feature flag

Functions

This section is empty.

Types

type ScheduleType added in v0.4.0

type ScheduleType string

ScheduleType defines the schedule type of a binding object should be performed.

const (
	// FirstSchedule means the binding object hasn't been scheduled.
	FirstSchedule ScheduleType = "FirstSchedule"

	// ReconcileSchedule means the binding object associated policy has been changed.
	ReconcileSchedule ScheduleType = "ReconcileSchedule"

	// FailoverSchedule means one of the cluster a binding object associated with becomes failure.
	FailoverSchedule ScheduleType = "FailoverSchedule"

	// AvoidSchedule means don't need to trigger scheduler.
	AvoidSchedule ScheduleType = "AvoidSchedule"

	// Unknown means can't detect the schedule type
	Unknown ScheduleType = "Unknown"
)

type Scheduler

type Scheduler struct {
	DynamicClient dynamic.Interface
	KarmadaClient karmadaclientset.Interface
	KubeClient    kubernetes.Interface

	Algorithm core.ScheduleAlgorithm
	// contains filtered or unexported fields
}

Scheduler is the scheduler schema, which is used to schedule a specific resource to specific clusters

func NewScheduler

func NewScheduler(dynamicClient dynamic.Interface, karmadaClient karmadaclientset.Interface, kubeClient kubernetes.Interface) *Scheduler

NewScheduler instantiates a scheduler

func (*Scheduler) Run

func (s *Scheduler) Run(ctx context.Context)

Run runs the scheduler

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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