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

Add a newAttachHeadersServerInterceptor() util #11458

Merged
merged 9 commits into from
Aug 14, 2024

Conversation

jdcormie
Copy link
Member

@jdcormie jdcormie commented Aug 9, 2024

No description provided.

@jdcormie jdcormie marked this pull request as ready for review August 9, 2024 00:47
// It isn't too late to call sendHeaders(): !headersSent implies that it hasn't been
// called yet (obviously). But it also implies that no messages have been sent, because
// sendMessage() *requires* a preceding call to sendHeaders().
sendHeaders(new Metadata());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, you're forcing headers. I don't think we want to do that generally. Maybe that is what you need, but I think it then stops being a general util.

Trailers-only is important to retries, as it delivers the status code without committing.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't know that - fixed and thanks!

@jdcormie jdcormie merged commit 6dbd1b9 into grpc:master Aug 14, 2024
13 checks passed
@jdcormie jdcormie deleted the server-metadata-int branch August 14, 2024 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants