config

package
v0.0.0-...-fdc4385 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppConfig

type AppConfig struct {
	DB *DBConfig
}

AppConfig ...

func GetConfig

func GetConfig() *AppConfig

GetConfig ...

type DBConfig

type DBConfig struct {
	Driver            string        `json:"driver"`
	URL               string        `json:"url"`
	MaxIdleConnection int           `json:"maxIdleConnection"`
	MaxOpenConnection int           `json:"maxOpenConnection"`
	ConnMaxLifetime   time.Duration `json:"connMaxLifetime"`
}

DBConfig store db config data

Environment Variables:

DB_DRIVER
DB_URL
DB_MAXIDLECONN
DB_MAXOPENCONN
DB_CONNMAXLIFE

Jump to

Keyboard shortcuts

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