conf

package
v0.0.0-...-83adff0 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2020 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// Conf conf
	Conf = &Config{}
)

Functions

func Init

func Init() (err error)

Init config

Types

type AgentConfig

type AgentConfig struct {
	Servers    []string         `toml:"servers"`
	Log        *log.Config      `toml:"log"`
	Queue      *QueueConfig     `toml:"queue"`
	UDPCollect UDPCollectConfig `toml:"udp_collect"`
}

AgentConfig config for dapper agent

func LoadAgentConfig

func LoadAgentConfig() (*AgentConfig, error)

LoadAgentConfig LoadAgentConfig

type BatchWriter

type BatchWriter struct {
	SummaryWorkers  int            `toml:"summary_workers"`
	SummaryBulkSize int            `toml:"summary_bulk_size"`
	SummaryChanSize int            `toml:"summary_chan_size"`
	RawWorkers      int            `toml:"raw_workers"`
	RawBufSize      int            `toml:"raw_buf_size"`
	RawChanSize     int            `toml:"raw_chan_size"`
	FlushInterval   xtime.Duration `toml:"flush_interval"`
}

BatchWriter config

type Collect

type Collect struct {
	Network string
	Addr    string
}

Collect config.

type Config

type Config struct {
	Log          *log.Config     `toml:"log"`
	HBase        *HBaseConfig    `toml:"hbase"`
	InfluxDB     *InfluxDBConfig `toml:"influx_db"`
	Collect      *Collect        `toml:"collect"`
	BatchWriter  *BatchWriter    `toml:"batch_writer"`
	Dapper       *DapperConfig   `toml:"dapper"`
	KafkaCollect *KafkaCollect   `toml:"kafka_collect"`
}

Config config.

type DapperConfig

type DapperConfig struct {
	RetentionDay int    `toml:"retention_day"`
	APIListen    string `toml:"api_listen"`
}

DapperConfig .

type HBaseConfig

type HBaseConfig struct {
	Namespace           string         `toml:"namespace"`
	Addrs               string         `toml:"addrs"`
	RPCQueueSize        int            `toml:"rpc_queue_size"`
	FlushInterval       xtime.Duration `toml:"flush_interval"`
	EffectiveUser       string         `toml:"effective_user"`
	RegionLookupTimeout xtime.Duration `toml:"region_lookup_timeout"`
	RegionReadTimeout   xtime.Duration `toml:"region_read_timeout"`
}

HBaseConfig hbase config

type InfluxDBConfig

type InfluxDBConfig struct {
	Addr     string `toml:"addr"`
	Username string `toml:"username"`
	Password string `toml:"password"`
	Database string `toml:"database"`
}

InfluxDBConfig InfluxDBConfig

type KafkaCollect

type KafkaCollect struct {
	Topic string   `toml:"topic"`
	Addrs []string `toml:"addrs"`
}

KafkaCollect .

type QueueConfig

type QueueConfig struct {
	// queue local stroage path
	MemBuckets  int    `toml:"mem_buckets"`
	BucketBytes int    `toml:"bucket_bytes"`
	CacheDir    string `toml:"cache_dir"`
}

QueueConfig internal queue config

type UDPCollectConfig

type UDPCollectConfig struct {
	Workers int    `toml:"workers"`
	Addr    string `toml:"addr"`
}

UDPCollectConfig collect config

Jump to

Keyboard shortcuts

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