config

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultConfigFile = "mongodb.conf.toml"

Variables

View Source
var (
	CommonConfig = &Config{Mongodb: DefaultMongodbConfig()}
)

Functions

This section is empty.

Types

type Config added in v0.0.3

type Config struct {
	Mongodb *MongodbConfig
}

func ReadConfigFile added in v0.0.3

func ReadConfigFile(files ...string) *Config

type MongodbConfig added in v0.0.3

type MongodbConfig struct {
	URI         string
	MaxPoolSize int
	MinPoolSize int
	Timeout     int //单位秒
}

func DefaultMongodbConfig added in v0.0.3

func DefaultMongodbConfig() *MongodbConfig

Jump to

Keyboard shortcuts

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