-
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
response_body of http rule is ignored in case of server streaming #1202
Comments
Hi Anil, thanks for the issue report! I think when we first added support for the The reason we're using a wrapper by default for streaming responses is so that users can use a single type to marshal the chunks, while still allowing us to return an error at any point in the stream. This means the error has to always be there. If a user were to use the ResponseBody though, we would allow the user to stream whatever they want. What ideas do you have for how to implement this? I can't promise it will be merged, but feel free to open a Pull Request and we can take a look together. |
Thanks @johanbrandhorst for quick response. can you take a look at following ? let me know it if creates side effects. thanks.
i am yet to find a way to test the changes. |
cool. will work on it. thanks. |
@johanbrandhorst raised CL (#1205). please take a look. generate step failed to due to proto error. not sure if this is something related to changes. pleae take a look and suggest. thanks. |
If the generate step failed it will be related to the changes. |
Please try regenerating locally by following the instructions in CONTRIBUTING.md |
after latest pull, seems it is failing in local too. But i didnt understand the error. not sure why it is referring to data in ResponseBodyOut .would you mind helping in pointing the error ?
|
i found the issue. not sure why it is there. let me fix. thanks. |
Fixed by #1208 |
HI Team,
response_body field of http rule is ignored in case of server streaming. i checked the template.go and handler.go, seems they are not checking ResponseBody type.
template.go
handler.go
Also noticed stream response is wrapped in a map here. is there any specific reason ?
Thanks
The text was updated successfully, but these errors were encountered: