Documentation
¶
Index ¶
- Constants
- func SmoothDelaySamples(conf Config, newDelay, oldDelay uint64) uint64
- type Acknowledgment
- type Config
- type Feedback
- type Receiver
- type Sender
- type SenderOnly
- func (s *SenderOnly) OnAck(seqNr uint64, departure, arrival time.Time, sizeBit uint64, marked bool)
- func (s *SenderOnly) OnAcks(rtt time.Duration, acks []Acknowledgment) (newRate uint64)
- func (s *SenderOnly) OnLoss(seqNr uint64, departure time.Time)
- func (s *SenderOnly) UpdateRTT(rtt time.Duration)
- func (s *SenderOnly) UpdateTargetRate() uint64
Constants ¶
View Source
const ( PRIO float64 = 1.0 RMIN uint64 = 150000 // bps RMAX uint64 = 1500000 // bps XREF uint64 = 10 // ms KAPPA float64 = 0.5 ETA float64 = 2.0 TAU uint64 = 500 // ms DELTA uint64 = 100 // ms LOGWIN uint64 = 500 // ms QEPS uint64 = 10 // ms DFILT uint64 = 120 // ms GAMMA_MAX float64 = 0.1 QBOUND uint64 = 50 // ms MULTILOSS float64 = 7.0 QTH uint64 = 50 // ms LAMBDA float64 = 0.5 PLRREF float64 = 0.01 PMRREF float64 = 0.01 DLOSS uint64 = 10 // ms DMARK uint64 = 2 // ms ALPHA float64 = 0.1 GRAD_UPDATE_FACTOR float64 = 0.02 )
Variables ¶
This section is empty.
Functions ¶
func SmoothDelaySamples ¶
Types ¶
type Acknowledgment ¶
type Acknowledgment struct {
SeqNr uint64
Departure time.Time
Arrival time.Time
SizeBit uint64
Marked bool
Arrived bool
}
Acknowledgment contains arrival information about one packet. Sender-only NADA requires these Acknowledgments.
type Config ¶
type Config struct {
Priority float64 // Weight of priority of the flow
MinRate uint64 // minimum rate supported by encoder in bps
MaxRate uint64 // maximum rate supported by encoder in bps
StartRate uint64 // at which rate NADA should start (default: MinRate)
RefCongLevel uint64 // Reference congestion level
Kappa float64 // Scaling parameter for gradual rate update calculation
Eta float64 // Scaling parameter for gradual rate update calculation
Tau uint64 // Upper bound of RTT in gradual rate update calculation
FeedbackDelta uint64 // Target feedback interval
LogWin uint64 // Observation window in time for calculating packet summary statistics at receiver
QEPS uint64 // Threshold for determining queuing delay buildup at receiver
DFILT uint64 // Bound on filtering delay for RampUp Mode
MaxRampUpFactor float64 // GAMMA_MAX: Upper bound on rate increase ratio for accelerated ramp up
MaxGradualUpdateFactor float64 // Upper/Lower bound on rate increase/decrease ratio for gradual updates
QBOUND uint64 // Upper bound on self-inflicted queuing delay during ramp up
MULTILOSS float64 // Multiplier for self-scaling the expiration threshold of the last observed loss (loss_exp) based on measured average loss interval (loss_int)
QTH uint64 // Delay threshold for invoking non-linear warping
LAMBDA float64 // Scaling parameter in the exponent of non-linear warping
PLRREF float64 // Reference packet loss ratio
PMRREF float64 // Reference packet marking ratio
DLOSS uint64 // Reference delay penalty for loss when packet loss ratio is at PLRREF
DMARK uint64 // Reference delay penalty for ECN marking when packet marking is at PM
ALPHA float64 // Smoothing factor in exponential smoothing of packet loss and marking ratios
DeactivateQDelayWrapping bool // do not apply wrapping of qdely
SmoothDelaySamples bool // Smooth delay samples with exponential moving average
UseDefaultGradualUpdates bool // Use default gradual update mode that depends on MaxRate
}
type Receiver ¶
type Receiver struct {
// contains filtered or unexported fields
}
Receiver: all timestamps are in microseconds
func NewReceiver ¶
func (*Receiver) GenerateFeedback ¶
GenerateFeedback for loss detection at sender. On time to send a new feedback report (t_curr - t_last > DELTA).
func (*Receiver) PacketArrived ¶
func (r *Receiver) PacketArrived( packetNumber uint64, departure time.Time, arrival time.Time, packetSizeBit uint64, marked bool, )
PacketArrived registers a new arrived packet. sentTs and recvTs are timestamps in microseconds. packetSize is the size of the packet in bits. marked: packet got ECN
type Sender ¶
type Sender struct {
// contains filtered or unexported fields
}
func (*Sender) FeedbackReport ¶
FeedbackReport calculates the new rate with the feedback from the receiver. recvRate, delay, queueBuildup are from the receiver feedback. rtt is the current rtt.
func (*Sender) LostPacket ¶
LostPacket registers a lost packet
type SenderOnly ¶
type SenderOnly struct {
// contains filtered or unexported fields
}
func NewSenderOnly ¶
func NewSenderOnly(config Config) SenderOnly
func (*SenderOnly) OnAcks ¶
func (s *SenderOnly) OnAcks(rtt time.Duration, acks []Acknowledgment) (newRate uint64)
func (*SenderOnly) UpdateRTT ¶
func (s *SenderOnly) UpdateRTT(rtt time.Duration)
func (*SenderOnly) UpdateTargetRate ¶
func (s *SenderOnly) UpdateTargetRate() uint64
Click to show internal directories.
Click to hide internal directories.