nmetrics

package
v0.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 22, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server interface {
	graceful.ShutdownServer

	RegisterCollectors(collectors ...prometheus.Collector) error

	MustRegisterCollectors(collectors ...prometheus.Collector)

	GrpcMetricsUnaryServerInterceptor() func(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)

	GrpcMetricsStramServerInterceptor() func(srv interface{}, ss grpc.ServerStream, info *grpc.StreamServerInfo, handler grpc.StreamHandler) error

	WebMetricsMiddleware() gin.HandlerFunc
}

Server -

func MustNewServer

func MustNewServer(config *nconf.Config, opt ...ServerOption) Server

MustNewServer -

func NewServer

func NewServer(config *nconf.Config, opt ...ServerOption) (Server, error)

NewServer -

type ServerOption

type ServerOption func(*serverOptions)

ServerOption -

func DBOption

func DBOption(db *gorm.DB) ServerOption

DBOption -

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL