-
Notifications
You must be signed in to change notification settings - Fork 4.5k
grpc: introduce new DialOption and ServerOption to configure initial window size without disabling BDP estimation. #8283
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 39 commits
0c8d8c3
3f776f2
a55c070
21f3aae
68f1322
699cb70
ab9e865
e72ed5b
541c8ce
5f9eeb4
2cb07fd
d077278
b2c9036
22cf9e1
2d3f20d
b94efb5
d05b590
c127d5f
21da04b
909bf84
e54e81b
d21bc12
cfaf50d
b422fce
605c49d
7a77cde
127227a
ac71fae
e5b7e2b
d3a6773
0b2d748
a3c4701
9abcf34
838385e
7ba8859
382ef30
48c91da
cf685db
35a2253
6ec9e7d
efe83f4
6d355fb
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -309,11 +309,10 @@ func NewHTTP2Client(connectCtx, ctx context.Context, addr resolver.Address, opts | |||||
scheme = "https" | ||||||
} | ||||||
} | ||||||
dynamicWindow := true | ||||||
icwz := int32(initialWindowSize) | ||||||
if opts.InitialConnWindowSize >= defaultWindowSize { | ||||||
icwz = opts.InitialConnWindowSize | ||||||
dynamicWindow = false | ||||||
opts.StaticWindowSize = false | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Don't alter the setting. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Done |
||||||
} | ||||||
writeBufSize := opts.WriteBufferSize | ||||||
readBufSize := opts.ReadBufferSize | ||||||
|
@@ -381,9 +380,9 @@ func NewHTTP2Client(connectCtx, ctx context.Context, addr resolver.Address, opts | |||||
t.controlBuf = newControlBuffer(t.ctxDone) | ||||||
if opts.InitialWindowSize >= defaultWindowSize { | ||||||
t.initialWindowSize = opts.InitialWindowSize | ||||||
dynamicWindow = false | ||||||
opts.StaticWindowSize = false | ||||||
} | ||||||
if dynamicWindow { | ||||||
if opts.StaticWindowSize { | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Done |
||||||
t.bdpEst = &bdpEstimator{ | ||||||
bdp: initialWindowSize, | ||||||
updateFlowControl: t.updateFlowControl, | ||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These (4) need to be
true
or you will be changing behavior, which is not what we want yet.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the clarification!, I've updated the code so that all four values are set to true