Documentation ¶
Index ¶
- Constants
- Variables
- type AgentMetrics
- func (a *AgentMetrics) EndpointConnectionDec()
- func (a *AgentMetrics) EndpointConnectionInc()
- func (a *AgentMetrics) ObserveDialFailure(reason DialFailureReason)
- func (a *AgentMetrics) ObserveDialLatency(elapsed time.Duration)
- func (a *AgentMetrics) ObservePacket(segment commonmetrics.Segment, packetType client.PacketType)
- func (a *AgentMetrics) ObserveServerFailureDeprecated(direction Direction)
- func (a *AgentMetrics) ObserveStreamError(segment commonmetrics.Segment, err error, packetType client.PacketType)
- func (a *AgentMetrics) ObserveStreamErrorNoPacket(segment commonmetrics.Segment, err error)
- func (a *AgentMetrics) Reset()
- func (a *AgentMetrics) SetServerConnectionsCount(count int)
- type DialFailureReason
- type Direction
Constants ¶
View Source
const ( Namespace = "konnectivity_network_proxy" Subsystem = "agent" // DirectionToServer indicates that the agent attempts to send a packet // to the proxy server. DirectionToServer Direction = "to_server" // DirectionFromServer indicates that the agent attempts to receive a // packet from the proxy server. DirectionFromServer Direction = "from_server" )
Variables ¶
View Source
var (
// Metrics provides access to all dial metrics.
Metrics = newAgentMetrics()
)
Functions ¶
This section is empty.
Types ¶
type AgentMetrics ¶
type AgentMetrics struct {
// contains filtered or unexported fields
}
AgentMetrics includes all the metrics of the proxy agent.
func (*AgentMetrics) EndpointConnectionDec ¶ added in v0.0.34
func (a *AgentMetrics) EndpointConnectionDec()
EndpointConnectionDec decrements a finished endpoint connection.
func (*AgentMetrics) EndpointConnectionInc ¶ added in v0.0.34
func (a *AgentMetrics) EndpointConnectionInc()
EndpointConnectionInc increments a new endpoint connection.
func (*AgentMetrics) ObserveDialFailure ¶ added in v0.0.34
func (a *AgentMetrics) ObserveDialFailure(reason DialFailureReason)
ObserveDialFailure records a remote endpoint dial failure.
func (*AgentMetrics) ObserveDialLatency ¶
func (a *AgentMetrics) ObserveDialLatency(elapsed time.Duration)
ObserveDialLatency records the latency of dial to the remote endpoint.
func (*AgentMetrics) ObservePacket ¶ added in v0.0.34
func (a *AgentMetrics) ObservePacket(segment commonmetrics.Segment, packetType client.PacketType)
func (*AgentMetrics) ObserveServerFailureDeprecated ¶ added in v0.0.34
func (a *AgentMetrics) ObserveServerFailureDeprecated(direction Direction)
ObserveServerFailure records a failure to send to or receive from the proxy server, labeled by the direction.
func (*AgentMetrics) ObserveStreamError ¶ added in v0.0.34
func (a *AgentMetrics) ObserveStreamError(segment commonmetrics.Segment, err error, packetType client.PacketType)
func (*AgentMetrics) ObserveStreamErrorNoPacket ¶ added in v0.0.34
func (a *AgentMetrics) ObserveStreamErrorNoPacket(segment commonmetrics.Segment, err error)
func (*AgentMetrics) SetServerConnectionsCount ¶ added in v0.0.34
func (a *AgentMetrics) SetServerConnectionsCount(count int)
type DialFailureReason ¶ added in v0.0.34
type DialFailureReason string
const ( DialFailureTimeout DialFailureReason = "timeout" DialFailureUnknown DialFailureReason = "unknown" )
Click to show internal directories.
Click to hide internal directories.