Documentation
¶
Index ¶
Constants ¶
View Source
const ( LoggingCategory = "LOGGING AND DEBUGGING" GenesisCategory = "GENESIS" RelayCategory = "RELAYS" GeneralCategory = "GENERAL" Metrics = "METRICS" )
Variables ¶
This section is empty.
Functions ¶
func MergeRelayConfigs ¶ added in v1.11.0
func MergeRelayConfigs(relays []types.RelayEntry, configMap map[string]types.RelayConfig) ([]types.RelayConfig, error)
MergeRelayConfigs merges relays passed via --relay with relays from config file. Returns an error if the same relay appears in both places. Users should specify each relay in exactly one place either cli or config file.
Types ¶
type Config ¶ added in v1.11.0
type Config struct {
TimeoutGetHeaderMs uint64 `yaml:"timeout_get_header_ms"`
LateInSlotTimeMs uint64 `yaml:"late_in_slot_time_ms"`
Relays []RelayConfigYAML `yaml:"relays"`
}
Config holds all configuration settings from the config file
type ConfigResult ¶ added in v1.11.0
type ConfigResult struct {
RelayConfigs map[string]types.RelayConfig
TimeoutGetHeaderMs uint64
LateInSlotTimeMs uint64
}
func LoadConfigFile ¶ added in v1.11.0
func LoadConfigFile(configPath string) (*ConfigResult, error)
LoadConfigFile loads configurations from a YAML file
type ConfigWatcher ¶ added in v1.11.0
type ConfigWatcher struct {
// contains filtered or unexported fields
}
ConfigWatcher provides hot reloading of config files
func NewConfigWatcher ¶ added in v1.11.0
func NewConfigWatcher(configPath string, cliRelays []types.RelayEntry, log *logrus.Entry) (*ConfigWatcher, error)
NewConfigWatcher creates a new config file watcher
func (*ConfigWatcher) Watch ¶ added in v1.11.0
func (cw *ConfigWatcher) Watch(onConfigChange func(*ConfigResult))
Watch starts watching the config file for changes
type RelayConfigYAML ¶ added in v1.11.0
type RelaySetupResult ¶ added in v1.11.0
type RelaySetupResult struct {
RelayConfigs []serverTypes.RelayConfig
MinBid types.U256Str
RelayCheck bool
TimeoutGetHeaderMs uint64
LateInSlotTimeMs uint64
CLIRelays []serverTypes.RelayEntry // CLI-provided relays for hot-reload merging
}
Click to show internal directories.
Click to hide internal directories.