config

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2026 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppConfig

type AppConfig struct {
	// TradingMode is paper|live. Empty defaults to paper after load.
	TradingMode string                    `yaml:"trading_mode"`
	Logger      logger.Config             `yaml:"logger"`
	Catalog     catalog.Config            `yaml:"catalog"`
	MsgBus      msgbus.Config             `yaml:"msgbus"`
	ExecRouter  []adapter.ExecRouterEntry `yaml:"execrouter"`
	DataRouter  []adapter.DataRouterEntry `yaml:"datarouter"`
	Node        node.Config               `yaml:"node"`
	// Runtime fences the Go runtime (GC off + memory limit, GOMAXPROCS);
	// see docs/DEPLOYMENT.md.
	Runtime telemetry.RuntimeConfig `yaml:"runtime"`
	// Metrics enables the /metrics + /gc HTTP endpoints.
	Metrics telemetry.MetricsConfig `yaml:"metrics"`
}

AppConfig is the top-level application configuration.

func LoadConfig

func LoadConfig(path string) (*AppConfig, error)

LoadConfig loads configuration from a YAML file. A relative catalog.instruments path is resolved against the config file's directory.

func LoadConfigFromBytes

func LoadConfigFromBytes(data []byte) (*AppConfig, error)

LoadConfigFromBytes loads configuration from YAML bytes.

func LoadConfigFromString

func LoadConfigFromString(data string) (*AppConfig, error)

LoadConfigFromString loads configuration from a YAML string.

Jump to

Keyboard shortcuts

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