Set default for RetxStartMs and change name to match westworld 3 name

This commit is contained in:
Paul Lorenz
2020-12-11 17:01:04 -05:00
parent ea6909717a
commit ea4d1de71b
2 changed files with 5 additions and 4 deletions
+1 -1
View File
@@ -99,7 +99,7 @@ func NewLinkSendBuffer(x *Xgress) *LinkSendBuffer {
newlyReceivedAcks: make(chan *Acknowledgement),
closeNotify: make(chan struct{}),
windowsSize: x.Options.TxPortalStartSize,
retxThreshold: x.Options.RetxInitial,
retxThreshold: x.Options.RetxStartMs,
retxScale: x.Options.RetxScale,
}
+4 -3
View File
@@ -39,7 +39,7 @@ type Options struct {
TxPortalDupAckScale float64
RxBufferSize uint32
RetxInitial uint32
RetxStartMs uint32
RetxScale float64
RetxAddMs uint32
MaxCloseWait time.Duration
@@ -95,8 +95,8 @@ func LoadOptions(data OptionsData) *Options {
if value, found := data["rxBufferSize"]; found {
options.RxBufferSize = uint32(value.(int))
}
if value, found := data["retxInitial"]; found {
options.RetxInitial = uint32(value.(int))
if value, found := data["retxStartMs"]; found {
options.RetxStartMs = uint32(value.(int))
}
if value, found := data["retxScale"]; found {
options.RetxScale = value.(float64)
@@ -129,6 +129,7 @@ func DefaultOptions() *Options {
TxPortalDupAckThresh: 64,
TxPortalDupAckScale: 0.9,
RxBufferSize: 4 * 1024 * 1024,
RetxStartMs: 200,
RetxScale: 2.0,
RetxAddMs: 100,
MaxCloseWait: 30 * time.Second,