config

package
v1.0.18 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2021 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetInt

func GetInt(path ...string) int

func GetString

func GetString(path ...string) string

func GetStringArray

func GetStringArray(path ...string) []string

func GetStringMap

func GetStringMap(path ...string) map[string]string

func Map

func Map() map[string]interface{}

func New

func New(sources ...string) error

New will load config from various config file file in Json format if same config param available in environment, environment param will take higher priority

func Reload

func Reload() error

func Scan

func Scan(t interface{}, path ...string) error

func Watch

func Watch() (goconfig.Watcher, error)

func WithEtcd

func WithEtcd(opt ...source.Option)

func WithEtcdAddress

func WithEtcdAddress(addr ...string) source.Option

func WithEtcdAuth added in v1.0.17

func WithEtcdAuth(user, pass string) source.Option

func WithEtcdTLSAuth added in v1.0.17

func WithEtcdTLSAuth(certFile, keyFile, caFile string) source.Option

func WithPath

func WithPath(path string) source.Option

Types

type Config

type Config goconfig.Config

Jump to

Keyboard shortcuts

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