Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Register ¶
func Register(ctx context.Context) (mongo.ClientOptionsPlugin, mongo.ClientPlugin)
Register registers a new health plugin on a new mongo client.
Types ¶
type Checker ¶
type Checker struct {
// contains filtered or unexported fields
}
Checker represents health checker plugin for mongoDB.
func NewChecker ¶
NewChecker returns a new checker plugin.
type Health ¶
type Health struct {
// contains filtered or unexported fields
}
Health represents a healh plugin for mongo.
func NewHealthWithConfigPath ¶
NewHealthWithConfigPath returns a new health with options from config path.
func NewHealthWithOptions ¶
NewHealthWithOptions returns a new health with options.
func (*Health) Register ¶
func (i *Health) Register(ctx context.Context) (mongo.ClientOptionsPlugin, mongo.ClientPlugin)
Register registers this health plugin on a new mongo client.
type Options ¶
Options represents health plugin for mongo options
func NewOptions ¶
NewOptions returns options from config file or environment vars.
func NewOptionsWithPath ¶
NewOptionsWithPath unmarshals a given key path into options and returns it.
Click to show internal directories.
Click to hide internal directories.