scheduler

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrServiceDisabled = errors.New("scheduler service is disabled")

Functions

func ConvertConfigurationForSimulator

func ConvertConfigurationForSimulator(versioned *configv1.KubeSchedulerConfiguration) (*configv1.KubeSchedulerConfiguration, error)

ConvertConfigurationForSimulator convert KubeSchedulerConfiguration to apply scheduler on simulator (1) It replaces all default-plugins with plugins for simulator. (2) It replaces Extenders config so that the connection is directed to the simulator server. (3) It converts KubeSchedulerConfiguration from configv1.KubeSchedulerConfiguration to config.KubeSchedulerConfiguration.

Types

type Service

type Service struct {
	// contains filtered or unexported fields
}

Service manages scheduler.

func NewSchedulerService

func NewSchedulerService(client clientset.Interface, restclientCfg *restclient.Config, initialSchedulerCfg *configv1.KubeSchedulerConfiguration, simulatorPort int) *Service

NewSchedulerService starts scheduler and return *Service.

func (*Service) ExtenderService

func (s *Service) ExtenderService() ExtenderService

ExtenderService returns ExtenderService interface.

func (*Service) GetSchedulerConfig

func (s *Service) GetSchedulerConfig() (*configv1.KubeSchedulerConfiguration, error)

func (*Service) ResetScheduler

func (s *Service) ResetScheduler() error

func (*Service) RestartScheduler

func (s *Service) RestartScheduler(cfg *configv1.KubeSchedulerConfiguration) error

RestartScheduler restarts the debuggable scheduler with a new config. Specifically, it updates the config file, which is also mounted on the debuggable scheduler, and then restart the debuggable scheduler.

func (*Service) SetSchedulerConfig added in v0.4.0

func (s *Service) SetSchedulerConfig(cfg *configv1.KubeSchedulerConfiguration)

func (*Service) ShutdownScheduler

func (s *Service) ShutdownScheduler()

Directories

Path Synopsis
mock_extender
Package mock_extender is a generated GoMock package.
Package mock_extender is a generated GoMock package.
mock
Package plugin is a generated GoMock package.
Package plugin is a generated GoMock package.
mock_storereflector
Package mock_storereflector is a generated GoMock package.
Package mock_storereflector is a generated GoMock package.

Jump to

Keyboard shortcuts

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