package
Version:
v0.2.7
Opens a new window with list of versions in this module.
Published: Dec 7, 2020
License: MIT
Opens a new window with license information.
Imports: 10
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
New 根据数据库名称,集合名称获取集合操作对象;参数顺序database_name,collection_name;
RegisterMongoDB 注册mongodb
type Config struct {
Database string `mapstructure:"db"`
Conn string `mapstructure:"conn"`
Username string `mapstructure:"username"`
Password string `mapstructure:"password"`
Timeout int `mapstructure:"timeout"`
MaxPool int `mapstructure:"max_pool"`
}
Config mongo配置
Source Files
¶
Click to show internal directories.
Click to hide internal directories.