Documentation ¶
Index ¶
Constants ¶
View Source
const ( DefaultClusterID = "my-kube-cluster" DefaultClusterVersion = "0.1" DefaultPolicyGroup = "queues" DefaultLoggingLevel = 0 DefaultLogEncoding = "console" DefaultVolumeBindTimeout = 10 * time.Second DefaultSchedulingInterval = time.Second DefaultEventChannelCapacity = 1024 * 1024 DefaultDispatchTimeout = 300 * time.Second DefaultKubeQPS = 1000 DefaultKubeBurst = 1000 )
default configuration values, these can be override by CLI options
Variables ¶
View Source
var ( BuildVersion string BuildDate string IsPluginVersion bool )
Functions ¶
func SetSchedulerConfFactory ¶
func SetSchedulerConfFactory(confFactory SchedulerConfFactory)
Types ¶
type SchedulerConf ¶
type SchedulerConf struct { SchedulerName string `json:"schedulerName"` ClusterID string `json:"clusterId"` ClusterVersion string `json:"clusterVersion"` PolicyGroup string `json:"policyGroup"` Interval time.Duration `json:"schedulingIntervalSecond"` KubeConfig string `json:"absoluteKubeConfigFilePath"` LoggingLevel int `json:"loggingLevel"` LogEncoding string `json:"logEncoding"` LogFile string `json:"logFilePath"` VolumeBindTimeout time.Duration `json:"volumeBindTimeout"` TestMode bool `json:"testMode"` EventChannelCapacity int `json:"eventChannelCapacity"` DispatchTimeout time.Duration `json:"dispatchTimeout"` KubeQPS int `json:"kubeQPS"` KubeBurst int `json:"kubeBurst"` Predicates string `json:"predicates"` OperatorPlugins string `json:"operatorPlugins"` EnableConfigHotRefresh bool `json:"enableConfigHotRefresh"` DisableGangScheduling bool `json:"disableGangScheduling"` UserLabelKey string `json:"userLabelKey"` PlaceHolderImage string `json:"placeHolderImage"` sync.RWMutex }
func GetSchedulerConf ¶
func GetSchedulerConf() *SchedulerConf
func (*SchedulerConf) GetKubeConfigPath ¶
func (conf *SchedulerConf) GetKubeConfigPath() string
func (*SchedulerConf) GetSchedulingInterval ¶
func (conf *SchedulerConf) GetSchedulingInterval() time.Duration
func (*SchedulerConf) IsOperatorPluginEnabled ¶
func (conf *SchedulerConf) IsOperatorPluginEnabled(name string) bool
func (*SchedulerConf) IsTestMode ¶
func (conf *SchedulerConf) IsTestMode() bool
func (*SchedulerConf) SetTestMode ¶
func (conf *SchedulerConf) SetTestMode(testMode bool)
type SchedulerConfFactory ¶
type SchedulerConfFactory = func() *SchedulerConf
Click to show internal directories.
Click to hide internal directories.