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
server: clarify documentation around setting and sending headers and ServerStream errors #5302
Conversation
…ServerStream errors
server.go
Outdated
// - An RPC status is sent out (error or success). This occurs when the handler | ||
// returns. | ||
// | ||
// SetHeader will fail if called after any of these events. |
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.
Make it more clear what these events
are?
"the events above"
?
Or move it above, right after the "send out" section
All the metadata will be sent out when one of the following happens, and SetHeader will fail if called after any of the events:
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.
Done (the former)
server.go
Outdated
// SetHeader will fail if called after any of these events. | ||
// | ||
// The error returned is compatible with the status package. However, the | ||
// status will often not match the status seen by the client application, and |
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.
the status code will often not
And did you want to say that the meanings of the codes are different from the client side? Or just that this code might be different from what the client functions return?
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.
Clarified. I intended the latter. The "meaning" of our codes is pretty variable already.
External documentation: please nit-pick.
RELEASE NOTES: