metrics

package
v0.0.0-...-0320a89 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2022 License: Apache-2.0 Imports: 8 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 struct {
	// contains filtered or unexported fields
}

Server simply defines a webserver to handle metrics exporting.

func NewServer

func NewServer() *Server

NewServer initializes a new server to handle metrics exporting.

func (*Server) InitializeMetrics

func (s *Server) InitializeMetrics(server *grpc.Server)

InitializeMetrics initializes all metrics for all gRPC methods registered on a GRPC server.

func (*Server) ListenAndServe

func (s *Server) ListenAndServe() error

ListenAndServe simply wraps the http router for the metrics endpoint.

func (*Server) Shutdown

func (s *Server) Shutdown(ctx context.Context) error

Shutdown simply wraps the http router for the metrics endpoint.

func (*Server) UnaryServerInterceptor

func (s *Server) UnaryServerInterceptor() grpc.UnaryServerInterceptor

UnaryServerInterceptor returns an intercaptor for the GRPC server to gather metrics.

Jump to

Keyboard shortcuts

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