- Prometheus metrics
- HTTP Healthcheck endpoint
- Soon: jaeger tracing
- Soon: GRPC healthcheck
./internal/mongo.go:
func (m *mongoPinger) Ping(ctx context.Context) {
ctx, _ = context.WithTimeout(ctx, pingTimeout)
return client.Ping(ctx, readpref.Primary())
}
./internal/healthcheck/options.go:
func WithMongoPinger(pinger db.Pinger) func(*checker) {
return func(c *checker) {
c.mongoPinger = pinger
}
}
HTTP_DEVOPS_ADDR
- addr for metics/healthcheck methods