setting

package
v0.0.0-...-c42e73f Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Appsetting = &App{}
View Source
var Elasticsetting = &Elastic{}
View Source
var Kafkasetting = &Kafka{}
View Source
var Logicsetting = &Logic{}
View Source
var MongoDbSetting = &MongoDB{}

Functions

func GetenvInt

func GetenvInt(target *int, init int, env string)

func GetenvStr

func GetenvStr(target *string, init, env string)

Types

type App

type App struct {
	Server string `toml:"address`
}

func (*App) Getenv

func (as *App) Getenv()

type Elastic

type Elastic struct {
	Addresses    []string `toml:"addresses"`
	RequestRetry int      `toml:"request_retry"`
	ChanBufSize  int      `toml:"chan_buf_size"`
	BatchTicker  int      `toml:"batch_ticker"`
	BatchSize    int      `toml:"batch_size"`
}

func (*Elastic) Getenv

func (es *Elastic) Getenv()

type Kafka

type Kafka struct {
	Broker      string   `toml:"broker"`
	GroupID     string   `toml:"group_id"`
	Topics      []string `toml:"topics"`
	ChanBufSize int      `toml:"chan_buf_size"`
}

func (*Kafka) Getenv

func (ks *Kafka) Getenv()

type Logic

type Logic struct {
	Server string
}

func (*Logic) Getenv

func (ls *Logic) Getenv()

type MongoDB

type MongoDB struct {
	Address string `toml:"address"`
	Port    string `toml:"port"`
}

func (*MongoDB) Getenv

func (ms *MongoDB) Getenv()

Jump to

Keyboard shortcuts

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