config

package
v0.0.0-...-00e1031 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2022 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseConfig

type BaseConfig struct {
	BasePath string `mapstructure:"basepath"`
}

type CollectorConfig

type CollectorConfig struct {
	Base      *BaseConfig      `mapstructure:"base"`
	Node      *NodeConfig      `mapstructure:"node"`
	LogClient *LogClientConfig `mapstructure:"logclient"`
	LogServer *LogServerConfig `mapstructure:"logserver"`
}

func NewCollectorConfig

func NewCollectorConfig(confPath string, configType string) (*CollectorConfig, error)

func (*CollectorConfig) Complete

func (c *CollectorConfig) Complete()

func (*CollectorConfig) Validate

func (c *CollectorConfig) Validate() bool

type LogClientConfig

type LogClientConfig struct {
	LoggerName string `mapstructure:"loggername"`
}

type LogServerConfig

type LogServerConfig struct {
	Address    string `mapstructure:"address"`
	LoggerName string `mapstructure:"loggername"`
}

type NodeConfig

type NodeConfig struct {
	RPC        *RPCConfig `mapstructure:"rpc"`
	LoggerName string     `mapstructure:"loggername"`
}

type RPCConfig

type RPCConfig struct {
	Address  string `mapstructure:"address"`
	Port     int    `mapstructure:"port"`
	Username string `mapstructure:"username"`
	Password string `mapstructure:"password"`
}

func (*RPCConfig) Complete

func (c *RPCConfig) Complete()

func (*RPCConfig) Validate

func (c *RPCConfig) Validate() bool

Jump to

Keyboard shortcuts

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