-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Change in behavior of streaming request body (1.4.1 vs 1.8.1) #894
Labels
Comments
Thanks for reporting this bug, as discussed this should be fairly easily resolved for the bidi and client streaming case by not using the ReaderUtil method (since we don't need it there anyway). |
See tmc/grpc-websocket-proxy#14 (comment) for more information. |
johanbrandhorst
pushed a commit
that referenced
this issue
Mar 6, 2019
An IOReaderFactory was being used to wrap request body for client/bidi streaming requests. This was causing the requests to be fully buffered before being sent to the grpc server, thereby breaking streaming. This commit changes that to directly use request body. Fixes #894
adasari
pushed a commit
to adasari/grpc-gateway
that referenced
this issue
Apr 9, 2020
An IOReaderFactory was being used to wrap request body for client/bidi streaming requests. This was causing the requests to be fully buffered before being sent to the grpc server, thereby breaking streaming. This commit changes that to directly use request body. Fixes grpc-ecosystem#894
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Steps you follow to reproduce the error:
I was using grpc-gateway (1.4.1) with github.com/tmc/grpc-websocket-proxy for using websockets to do bidirectional streaming. I recently updated to 1.8.1 and noticed that my web client was not behaving as expected. Further analysis showed that:
I also saw that this issue has been reported on the websocket-proxy project.
It seems that the communication between the websocket proxy and the grpc server is blocked by ioutil.ReadAll. If I used a modified websocket proxy code that closes the request body after a few messages, the grpc server receives all the messages.
What did you expect to happen instead:
The grpc server should receive each message as the websocket sends it.
What's your theory on why it isn't working:
This does seem to be related to the ioutil.ReadAll on the request Body.
The text was updated successfully, but these errors were encountered: