metrics

package
v0.23.0 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2024 License: Apache-2.0 Imports: 2 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ActiveTests = promauto.NewGaugeVec(
		prometheus.GaugeOpts{
			Name: "ndt_active_tests",
			Help: "A gauge of requests currently being served by the NDT server.",
		},
		[]string{"protocol"})
	TestRate = promauto.NewHistogramVec(
		prometheus.HistogramOpts{
			Name: "ndt_test_rate_mbps",
			Help: "A histogram of request rates.",
			Buckets: []float64{
				.1, .15, .25, .4, .6,
				1, 1.5, 2.5, 4, 6,
				10, 15, 25, 40, 60,
				100, 150, 250, 400, 600,
				1000},
		},
		[]string{"protocol", "direction", "monitoring"},
	)
)

Metrics for general use, in both NDT5 and in NDT7.

Functions

func GetResultLabel added in v0.18.0

func GetResultLabel(err error, rate float64) string

GetResultLabel returns one of four strings based on the combination of whether the error ("okay" or "error") and the rate ("with-rate" (non-zero) or "without-rate" (zero)).

Types

This section is empty.

Jump to

Keyboard shortcuts

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