-
Notifications
You must be signed in to change notification settings - Fork 9.8k
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
*: fragment watch response by server request limit #9291
Conversation
742810c
to
04d7f90
Compare
9073a41
to
e3ff373
Compare
e3ff373
to
ed2ce97
Compare
@SuhasAnand Can you give this a try? The client receive limit error should be resolved via |
ed2ce97
to
8795633
Compare
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Signed-off-by: Gyuho Lee <[email protected]>
Did benchmark of total 120 MiB watch events, each of which contains 1.2 MiB value, so that server would split one watch response with 100 fragmented event:
So, fragmentation would only have minimal overhead (mostly over the network), which is expected. There's no noticeable performance change and fragmentation will be disabled by default. |
@gyuho lgtm. Thanks! |
Replace #8371.
Address #8188 and #9294.
If watch response exceeds server-side request limit, it automatically splits watch response events and sends fragments over RPC. Clients still receive combined results, while the server-to-client dispatch happens with fragments.
Given this use case:
--max-request-bytes '1572864'
(1.5 MiB)clientv3.MaxCallRecvMsgSize
is 1.5 MiBWithout this patch, fail with error
code = ResourceExhausted desc = grpc: received message larger than max (10486027 vs. 1572864)
. With this patch, 100 events will be split over 100 fragmented watch response in server-side, then joined back in client before it being returned to the user.Nothing changes from user's perspective.