Documentation ¶
Index ¶
- Constants
- func CloseDatabaseClient(temp *DatabaseClientId)
- func CloseDatabaseClientsByMongoClientId(temp *MongoClientId)
- func CloseMongoClient(temp *MongoClientId)
- func CreateDatabaseClient(temp *DatabaseClient)
- func CreateMongoClient(temp *MongoClient)
- func GetDatabaseClient(temp *DatabaseClientId) (*mongo.Database, error)
- func GetMongoClient(temp *MongoClientId) (*mongo.Client, error)
- type Conf
- type DatabaseClient
- type DatabaseClientId
- type DatabaseClients
- type DatabaseConf
- type MongoClient
- type MongoClientId
- type MongoClients
Constants ¶
View Source
const ( ERROR_CLIENT_INSTANCE = "mongodb_connection : failed to get the mongodb client" ERROR_DATABASE_INSTANCE = "mongodb_database_connection : failed to get the mongodb database client" )
Variables ¶
This section is empty.
Functions ¶
func CloseDatabaseClient ¶
func CloseDatabaseClient(temp *DatabaseClientId)
func CloseDatabaseClientsByMongoClientId ¶
func CloseDatabaseClientsByMongoClientId(temp *MongoClientId)
func CloseMongoClient ¶
func CloseMongoClient(temp *MongoClientId)
func CreateDatabaseClient ¶
func CreateDatabaseClient(temp *DatabaseClient)
func CreateMongoClient ¶
func CreateMongoClient(temp *MongoClient)
func GetDatabaseClient ¶
func GetDatabaseClient(temp *DatabaseClientId) (*mongo.Database, error)
func GetMongoClient ¶
func GetMongoClient(temp *MongoClientId) (*mongo.Client, error)
Types ¶
type DatabaseClient ¶
type DatabaseClient struct { Id *DatabaseClientId Once *sync.Once Conf *DatabaseConf Err *error // contains filtered or unexported fields }
type DatabaseClientId ¶
type DatabaseClientId struct {
Id string
}
type DatabaseClients ¶
type DatabaseClients struct {
// contains filtered or unexported fields
}
type DatabaseConf ¶
type DatabaseConf struct { DatabaseName string MongoClientId *MongoClientId }
type MongoClient ¶
type MongoClientId ¶
type MongoClientId struct {
Id string
}
type MongoClients ¶
type MongoClients struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.