Verify deadlines are correctly propagated #772
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I noticed in the code the other day that we do verify the timeout, by having the server echo back the timeout it observed and then having the test runner check that against the timeout that the client should have sent.
So I was surprised that this didn't manifest as failed tests in connect-kotlin, which I now know (from getting pretty deep into the code) does not work -- it simply never tried to set deadline headers. (And it's not easy to add with it's current implementation structure, so I'll probably leave it as "known failing" until we can fix other problems with timeouts.)
Anyhow, when digging into why this didn't tickle any failure in connect-kotlin, it's because the only test cases that actually set the timeout always fail with a timeout error (so the client never gets back a response and cannot see the timeout that the server observed).
So this adds a new test suite to verify deadlines are correctly propagated. And it also required some fixes in the grpc-go server implementation in this repo, which was not reporting them correctly, which caused failures in the
make runservertests
target.