Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Host string
Port int
Balancer balancer.Balancer
Registry map[string][]string
ReverseProxy proxy.ReverseProxy
}
Config holds then configured values and objects to be used by the scheduler.
func CreateDefaultConfig ¶
func CreateDefaultConfig() Config
type JSONConfig ¶
type JSONConfig struct {
Host string `json:"host"`
Port int `json:"port"`
Balancer string `json:"balancer"`
LoadThreshold int `json:"load-threshold"`
Registry string `json:"registry"`
Workers []string `json:"workers"`
}
JSONConfig holds the data configured via a JSON file. This shall be used to parse the JSON file and create a proper Config struct that dictates the scheduler's behavior.
func LoadConfigFromFile ¶
func LoadConfigFromFile(configFilepath string) JSONConfig
func (JSONConfig) ToConfig ¶
func (c JSONConfig) ToConfig() Config
Click to show internal directories.
Click to hide internal directories.