Skip to content

Commit

Permalink
Incorporate TxProfile into WestworldProfile. (#132)
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelquigley committed Aug 25, 2021
1 parent bde5634 commit 859a668
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
10 changes: 10 additions & 0 deletions algorithm.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,13 @@ type TxProfile struct {
ConnectionTimeout time.Duration
MaxTreeSize int
}

func DefaultTxProfile() *TxProfile {
return &TxProfile{
MaxSegmentSize: 1450,
RetxBatchMs: 2,
SendKeepalive: true,
ConnectionTimeout: 15000,
MaxTreeSize: 64 * 1024,
}
}
2 changes: 2 additions & 0 deletions westworld.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ type WestworldProfile struct {
RxSizePressureScale float64
RttProbeMs int
RttProbeAvg int
Txpf *TxProfile
}

func NewBaselineWestworldProfile() *WestworldProfile {
Expand All @@ -177,5 +178,6 @@ func NewBaselineWestworldProfile() *WestworldProfile {
RxSizePressureScale: 2.8911,
RttProbeMs: 50,
RttProbeAvg: 8,
Txpf: DefaultTxProfile(),
}
}

0 comments on commit 859a668

Please sign in to comment.