Skip to content
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

Merged
merged 4 commits into from Apr 8, 2022

Conversation

dfawley
Copy link
Member

@dfawley dfawley commented Apr 7, 2022

External documentation: please nit-pick.

RELEASE NOTES:

  • server: clarify documentation around setting and sending headers and ServerStream errors

@dfawley dfawley added the Type: Documentation Documentation or examples label Apr 7, 2022
@dfawley dfawley added this to the 1.47 Release milestone Apr 7, 2022
@dfawley dfawley requested a review from menghanl April 7, 2022 22:18
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.
Copy link
Contributor

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:

Copy link
Member Author

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
Copy link
Contributor

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?

Copy link
Member Author

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.

@menghanl menghanl assigned dfawley and unassigned menghanl Apr 7, 2022
@dfawley dfawley merged commit 9711b14 into grpc:master Apr 8, 2022
@dfawley dfawley deleted the serverstatus branch April 8, 2022 20:11
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 6, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Type: Documentation Documentation or examples
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants