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

transport: double-check deadline when processing server cancelation #2211

Merged
merged 1 commit into from
Jul 10, 2018

Conversation

dfawley
Copy link
Member

@dfawley dfawley commented Jul 10, 2018

@dfawley dfawley added this to the 1.14 Release milestone Jul 10, 2018
if d, ok := s.ctx.Deadline(); ok && d.After(time.Now()) {
statusCode = codes.DeadlineExceeded
}
}
t.closeStream(s, io.EOF, false, http2.ErrCodeNo, status.Newf(statusCode, "stream terminated by RST_STREAM with error code: %v", f.ErrCode), nil, false)
Copy link
Contributor

Choose a reason for hiding this comment

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

Also change the error message when it's deadline?

Copy link
Member Author

Choose a reason for hiding this comment

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

Let's leave it this way for now, since the RST_STREAM and code are still correct and potentially meaningful.

@dfawley dfawley merged commit e85134f into grpc:master Jul 10, 2018
@dfawley dfawley deleted the dblchk branch July 11, 2018 17:15
@lock lock bot locked as resolved and limited conversation to collaborators Jan 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants