metrics

package
v1.75.3 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Observer

type Observer struct {
	// contains filtered or unexported fields
}

Observer holds connection metrics.

func NewObserver

func NewObserver(p Params) *Observer

NewObserver returns observer for emitting connection metrics.

func (*Observer) IncPlaintextConnections

func (o *Observer) IncPlaintextConnections()

IncPlaintextConnections increments plaintext connections metric.

func (*Observer) IncTLSConnections

func (o *Observer) IncTLSConnections(version uint16)

IncTLSConnections increments TLS connections metric.

func (*Observer) IncTLSHandshakeFailures

func (o *Observer) IncTLSHandshakeFailures()

IncTLSHandshakeFailures increments TLS handshake failures metric.

type Params

type Params struct {
	Meter         *metrics.Scope
	Logger        *zap.Logger
	ServiceName   string // Name of the service.
	TransportName string // Name of the transport.
	Direction     string // Inbound or Outbound.
	Dest          string // Name of the dest, only for outbound.
	Mode          yarpctls.Mode
}

Params holds parameters needed for creating new observer.

Jump to

Keyboard shortcuts

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