config

package
v0.0.0-...-63a9e4b Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ServerPort int // NEVER USED

Functions

func InitDBConn

func InitDBConn()

Types

type Config

type Config struct {
	// NEVER USED
	Server ServerConfig
	Db     DatabaseConfig
}

func InitConfig

func InitConfig() *Config

type DatabaseConfig

type DatabaseConfig struct {
	Name              string   `yaml:"-"`
	Username          string   `yaml:"username"`
	Password          string   `yaml:"password"`
	Hosts             []string `yaml:"hosts"`
	Database          string   `yaml:"database"`
	Desc              string   `yaml:"desc"`
	Url               string   `yaml:"url"`
	ConnectionTimeout int64    `yaml:"connectionTimeout"`
	MaxOpenConns      int      `yaml:"maxOpenConns"`
	MaxIdleConns      int      `yaml:"maxIdleConns"`
}

func InitDatabaseConfig

func InitDatabaseConfig() *DatabaseConfig

type ServerConfig

type ServerConfig struct {
	// NEVER USED
	Port int
}

Jump to

Keyboard shortcuts

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