metrics_reporter

package
v0.0.0-...-3216bbb Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2024 License: Apache-2.0 Imports: 11 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DurationMs

type DurationMs string

func (DurationMs) Send

func (name DurationMs) Send(duration uint64)

type MetricsEmitter

type MetricsEmitter interface {
	Emit(*MetricsReport)
}

func NewMetricsEmitter

func NewMetricsEmitter() MetricsEmitter

type MetricsReport

type MetricsReport struct {
	TotalCurrentQueuedRequests   uint64
	TotalBackendConnectionErrors uint64
	AverageQueueTimeMs           uint64
	AverageConnectTimeMs         uint64
	ProxyMetrics                 map[models.RoutingKey]ProxyStats
	RouteErrorMap                map[string]uint64
}

func Convert

func Convert(proxyStats haproxy_client.HaproxyStats) *MetricsReport

type MetricsReporter

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

func NewMetricsReporter

func NewMetricsReporter(clock clock.Clock, haproxyClient haproxy_client.HaproxyClient, metricsEmitter MetricsEmitter, interval time.Duration, logger lager.Logger) *MetricsReporter

func (*MetricsReporter) Run

func (r *MetricsReporter) Run(signals <-chan os.Signal, ready chan<- struct{}) error

type ProxyDurationMs

type ProxyDurationMs string

func (ProxyDurationMs) Send

func (name ProxyDurationMs) Send(proxyName string, duration uint64)

type ProxyStats

type ProxyStats struct {
	ConnectionTime  uint64
	CurrentSessions uint64
}

type ProxyValue

type ProxyValue string

func (ProxyValue) Send

func (name ProxyValue) Send(proxyName string, value uint64)

type RouteErrorReport

type RouteErrorReport struct {
	RouteErrors map[models.RoutingKey]uint64
}

type Value

type Value string

func (Value) Send

func (name Value) Send(value uint64)

Directories

Path Synopsis
This file was generated by counterfeiter
This file was generated by counterfeiter
fakes
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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