nw_congestion

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CurrentInitCongestionWindow

func CurrentInitCongestionWindow() int

Initial congestion window size

func CurrentMaxCongestionWindow

func CurrentMaxCongestionWindow() int

Maximum congestion window size

func CurrentMinCongestionWindow

func CurrentMinCongestionWindow() int

Minimum congestion window size

func EndRateLimit

func EndRateLimit(hash, endpoint string, reset time.Time)

func EndSuccess

func EndSuccess(hash, endpoint string)

func EndTransportError

func EndTransportError(hash, endpoint string)

func SetInitCongestionWindow

func SetInitCongestionWindow(w int)

func SetMaxCongestionWindow

func SetMaxCongestionWindow(w int, ignoreHardLimit bool)

func Start

func Start(hash, endpoint string)

Types

type CongestionControl

type CongestionControl interface {
	// start and wait for QoS
	Start(hash, endpoint string)

	// mark transaction as success
	EndSuccess(hash, endpoint string)

	// mark transaction as transport error
	EndTransportError(hash, endpoint string)

	// mark transaction as failure and got a rate limit
	EndRateLimit(hash, endpoint string, reset time.Time)
}

func NewControl

func NewControl() CongestionControl

Jump to

Keyboard shortcuts

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