config

package
v0.0.0-...-1679dbc Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	PDAddr     string `toml:"pd" json:"pd"`
	StatusAddr string `toml:"status" json:"status"`

	Log      log.Config `toml:"log" json:"log"`
	Logger   *zap.Logger
	LogProps *log.ZapProperties

	Client int64 `toml:"client" json:"client"`

	// tls
	CaPath   string `toml:"ca-path" json:"ca-path"`
	CertPath string `toml:"cert-path" json:"cert-path"`
	KeyPath  string `toml:"key-path" json:"key-path"`

	// only for init
	HTTP map[string]cases.Config `toml:"http" json:"http"`
	GRPC map[string]cases.Config `toml:"grpc" json:"grpc"`
	ETCD map[string]cases.Config `toml:"etcd" json:"etcd"`
	// contains filtered or unexported fields
}

Config is the heartbeat-bench configuration.

func NewConfig

func NewConfig(flagSet *flag.FlagSet) *Config

NewConfig return a set of settings.

func (*Config) Adjust

func (c *Config) Adjust()

Adjust is used to adjust configurations

func (*Config) InitCoordinator

func (c *Config) InitCoordinator(co *cases.Coordinator)

InitCoordinator set case config from config itself.

func (*Config) Parse

func (c *Config) Parse(arguments []string) error

Parse parses flag definitions from the argument list.

Jump to

Keyboard shortcuts

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