config

package
v0.0.0-...-ceb1bbd Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var FilePath string

The config file path used by Load config

Functions

This section is empty.

Types

type Config

type Config struct {
	LogLevel        int8                   `json:"log_level"      yaml:"log_level"      env:"LOG_LEVEL" validate:"gte=1,lte=5"`
	ZeppelinAddress string                 `json:"zeppelin_address"      yaml:"zeppelin_address"      env:"ZEPPELIN_ADDRESS" validate:"required"`
	GRPCServer      *grpcwrap.ServerConfig `json:"grpc_server"    yaml:"grpc_server"    env:"GRPC_SERVER"         validate:"required"`
	MetricsServer   *metrics.Config        `json:"metrics_server" yaml:"metrics_server" env:"METRICS_SERVER"      validate:"required"`
	MySQL           *gormwrap.MySQLConfig  `json:"mysql"          yaml:"mysql"          env:"MYSQL"               validate:"required"`
	//ETCD                  *getcd.Config          `json:"etcd"           yaml:"etcd"           env:"ETCD"                validate:"required"`
	Tracer       *gtrace.Config         `json:"tracer"         yaml:"tracer"         env:"TRACER"              validate:"required"`
	SpaceManager *grpcwrap.ClientConfig `json:"space_manager"  yaml:"space_manager"  env:"SPACE_MANAGER"       validate:"required"`
}

Config is the configuration settings for spacemanager

func Load

func Load() (cfg *Config, err error)

LoadConfig load all configuration from specified file Must be set `FilePath` before called

Jump to

Keyboard shortcuts

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