Documentation ¶
Index ¶
- type Mongo
- func (m *Mongo) Client() *mongo.Client
- func (m *Mongo) Col(col bson.M) *mongo.Collection
- func (m *Mongo) Connect(ctx context.Context)
- func (m *Mongo) ConnectDefault(ctx context.Context)
- func (m *Mongo) Disconnect(ctx context.Context)
- func (m *Mongo) InitCollection(col bson.M)
- func (m *Mongo) M() *Mongo
- func (m *Mongo) Ping(ctx context.Context, rp *readpref.ReadPref)
- type MongoChanPool
- type MongoRingPool
- type Mongoer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Mongo ¶
type Mongo struct {
// contains filtered or unexported fields
}
func (*Mongo) ConnectDefault ¶
func (*Mongo) Disconnect ¶
func (*Mongo) InitCollection ¶
type MongoChanPool ¶
type MongoChanPool struct {
// contains filtered or unexported fields
}
func NewMongoChanPool ¶
func NewMongoChanPool(name string, maxPoolSize int, opts ...*options.ClientOptions) *MongoChanPool
func (*MongoChanPool) Disconnect ¶
func (m *MongoChanPool) Disconnect(ctx context.Context)
func (*MongoChanPool) M ¶
func (m *MongoChanPool) M() *Mongo
type MongoRingPool ¶
type MongoRingPool struct {
// contains filtered or unexported fields
}
func NewMongoRingPool ¶
func NewMongoRingPool(name string, maxPoolSize int, opts ...*options.ClientOptions) *MongoRingPool
func (*MongoRingPool) Disconnect ¶
func (m *MongoRingPool) Disconnect(ctx context.Context)
func (*MongoRingPool) M ¶
func (m *MongoRingPool) M() *Mongo
Click to show internal directories.
Click to hide internal directories.