web100

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: 6 Imported by: 2

Documentation

Overview

Package web100 provides web100 variables (or a simulation thereof) to interested systems. When run on not-BBR it is polling-based, when run on BBR it only needs to measure once.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MeasureViaPolling

func MeasureViaPolling(ctx context.Context, ci netx.ConnInfo) <-chan *Metrics

MeasureViaPolling collects all required data by polling and returns a channel for the results. This function may or may not send socket information along the channel, depending on whether or not an error occurred. The value is sent along the channel sometime after the context is canceled.

Types

type Metrics

type Metrics struct {
	// Milliseconds
	MaxRTT, MinRTT, SumRTT, CurRTO, SndLimTimeCwnd, SndLimTimeRwin, SndLimTimeSender uint32

	// Counters
	DataBytesOut                                                           uint64
	DupAcksIn, PktsOut, PktsRetrans, Timeouts, CountRTT, CongestionSignals uint32
	AckPktsIn                                                              uint32 // Called SegsIn in tcp-kis.txt

	// Octets
	MaxCwnd, MaxRwinRcvd, CurMSS, Sndbuf uint32

	// Scaling factors
	RcvWinScale, SndWinScale int

	// Useful metrics that are not part of the required set.
	BytesPerSecond float64
	TCPInfo        tcp.LinuxTCPInfo
}

Metrics holds web100 data. According to the NDT5 protocol, each of these metrics is required. That does not mean each is required to be non-zero, but it does mean that the field should be present in any response.

Jump to

Keyboard shortcuts

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