config

package
v0.0.0-...-56ec27c Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2020 License: Apache-2.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 Configuration

type Configuration struct {
	Logger   LoggerParams   `yaml:"logger"`
	Database DatabaseParams `yaml:"database"`
	Server   ServerParams   `yaml:"server"`
	Queue    QueueParams    `yaml:"queue"`
}

func NewConfig

func NewConfig(configPath string) *Configuration

func (*Configuration) GetDatabasePath

func (cfg *Configuration) GetDatabasePath() string

func (*Configuration) ZapConfigBuilder

func (cfg *Configuration) ZapConfigBuilder() zap.Config

type DatabaseParams

type DatabaseParams struct {
	Path string `yaml:"path"`
}

type LoggerParams

type LoggerParams struct {
	Output   []string `yaml:"output"`
	Error    []string `yaml:"error"`
	Level    string   `yaml:"level"`
	Encoding string   `yaml:"encoding"`
}

type QueueParams

type QueueParams struct {
	Path string `yaml:"path"`
}

type ServerParams

type ServerParams struct {
	HTTP string `yaml:"http"`
	GRPC string `yaml:"grpc"`
}

Jump to

Keyboard shortcuts

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