config

package
v0.0.0-...-248868a Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadModuleConfig

func ReadModuleConfig(path string) interface{}

Types

type Config

type Config struct {
	Rest struct {
		AppName         string `json:"app"`
		Port            string `json:"port"`
		GracefulTimeout int    `json:"graceful_timeout"`
		ReadTimeout     int    `json:"read_timeout"`
		WriteTimeout    int    `json:"write_timeout"`
		DefaultTimeout  int    `json:"api_timeout"`
	} `json:"rest"`
	Logger struct {
		Level  string `json:"level"`
		Format string `json:"format"`
	} `json:"logger"`
	Kafka struct {
		Brokers []string `json:"brokers"`
	} `json:"kafka"`
	Wallet struct {
		Threshold     int   `json:"threshold"`
		RollingPeriod int64 `json:"rolling_period"`
	} `json:"wallet"`
}
var GlobalConfig *Config

Jump to

Keyboard shortcuts

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