config

package
v0.1.8 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ServiceName - default service name.
	ServiceName       = "grpc"
	ClientServiceName = "grpc"

	APIVersion = "v1"

	DefaultConfigPath = "config/default.conf"

	DefaultServerPort                 = 8000
	DefaultInfoPort                   = 8080
	DefaultClientBalancer             = "round_robin"
	DefaultClientInsecure             = false
	DefaultClientEnvoyProxy           = false
	DefaultClientWaitForReady         = false
	DefaultClientTimeout              = 15
	DefaultClientKeepAliveTime        = 10
	DefaultClientKeepAliveTimeout     = 5
	DefaultClientKeepAliveForce       = false
	DefaultClientRetryActive          = false
	DefaultClientEnvoyRetryReason     = "5xx"
	DefaultClientEnvoyRetryGRPCReason = "unavailable"
	DefaultClientEnvoyRetryCount      = 30
	DefaultClientEnvoyRetryTimeout    = 5
	DefaultClientBackoffMultiplier    = 1.6
	DefaultClientBackoffJitter        = 0.2
	DefaultClientBackoffDelayMin      = 1
	DefaultClientBackoffDelayMax      = 120
	DefaultServerConnectionIdle       = 0
	DefaultServerConnectionAge        = 0
	DefaultServerConnectionAgeGrace   = 0
	DefaultServertKeepAliveTime       = 300
	DefaultServerKeepAliveTimeout     = 10
	DefaultGracePeriod                = 30
	DefaultInfoStatistics             = true
	DefaultLoggerLevel                = logger.LevelInfo
)

Default values: host, port, etc.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Client client.Config
	Server server.Config
	Info   info.Config
	Logger logger.Config
	System system.Config
}

Config -- Base config structure.

func New

func New() (*Config, error)

New - returns new config record initialized with default values. nolint: funlen

Jump to

Keyboard shortcuts

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