metrics

package
v0.0.23 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2021 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// Proxy is the ProxyService method used to handle incoming streams.
	Proxy = "Proxy"

	// Connect is the AgentService method used to establish next hop.
	Connect = "Connect"
)

Variables

View Source
var (

	// Metrics provides access to all dial metrics.
	Metrics = newServerMetrics()
)

Functions

This section is empty.

Types

type ServerMetrics

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

ServerMetrics includes all the metrics of the proxy server.

func (*ServerMetrics) ConnectionDec added in v0.0.17

func (a *ServerMetrics) ConnectionDec(serviceMethod string)

ConnectionDec decrements a finished grpc client connection.

func (*ServerMetrics) ConnectionInc added in v0.0.17

func (a *ServerMetrics) ConnectionInc(serviceMethod string)

ConnectionInc increments a new grpc client connection.

func (*ServerMetrics) ObserveDialLatency

func (a *ServerMetrics) ObserveDialLatency(elapsed time.Duration)

ObserveDialLatency records the latency of dial to the remote endpoint.

func (*ServerMetrics) ObserveFrontendWriteLatency added in v0.0.20

func (a *ServerMetrics) ObserveFrontendWriteLatency(elapsed time.Duration)

ObserveFrontendWriteLatency records the latency of dial to the remote endpoint.

func (*ServerMetrics) Reset

func (a *ServerMetrics) Reset()

Reset resets the metrics.

func (*ServerMetrics) SetBackendCount added in v0.0.20

func (a *ServerMetrics) SetBackendCount(count int)

SetBackendCount sets the number of backend connection.

func (*ServerMetrics) SetPendingDialCount added in v0.0.23

func (a *ServerMetrics) SetPendingDialCount(count int)

SetPendingDialCount sets the number of pending dials.

Jump to

Keyboard shortcuts

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