* Closes the client transport stream, if context is cancelled while recvBuffer is reading.
* Passes a function pointer to recvBufferReader, instead of a Stream and an http2Client.
* Adds more descriptive error messages.
* If waitOnHeader notices the context cancelation, shouldRetry no longer returns a ContextError. Instead, it returns the error from the last try.
* Makes sure that test gets both statuses at least 5 times.
* Makse cntPermDenied a lambda function.
* Adds unconstrained streaming benchmarks.
* Adds throughput to all scenarios.
* Adds comment to exported function.
* Adds comment to the new rpc.
* Adds a new run mode for unconstrained benchmarks.
* Converts counters to uint64s.
* Decreases default warm up time.
* Addresses PR comments.
* Deletes an unnecessary select/case
* Explains the use of RecvMsg rather than Recv.
Staticcheck has a -go option which I _believe_ was recently added. This allows
us to pin to 1.9, preventing staticcheck from recommending we optimize to an
overly-recent version of Go.
- Remove the slice of servers approach, since there's specific
logic at server 2 that's different from server 1. This has the
advantage of making the test more readable without sacrificing
anything (given the previous point).
- Defer server close at initialization time instead of at the
end.
- Remove a time.Sleep(time.Second): use timeout + select around
serverDone instead.
- Use a goroutine to keep the connection reading, instead of
using a for loop in the server goroutine. This causes the
defer close(server2Done) to happen immediately after preface
is sent, which combined with the aforementioned time.Sleep
removal causes the test to go from 1.00s to ~0.05s.
The status package now has `Convert()` and `Code()` utilities.
This patch updates the deprecation description for `ErrorDesc()` and
`Code()` to recommend using those functions, and forward the deprecated
functions to use the `status.Code()` and `status.Convert()` functions.
Previously, the transport was able to reset via the retry loop,
or via the event closures calling resetTransport. This meant
a very large amount of synchronization was necessary: one
reset meant the other had to not reset; state had to be kept
at the addrconn; and very subtle interactions were hard to
reason about.
This change removes the ability for event closures to directly
reset the transport. Instead, they signal to to the retry
loop about the event, and the retry loop is always the single
place that retries occur.
This also allows us to refactor the address switching logic
into a much simpler for loop inside the retry loop instead of
using addrConn state to keep track of an index.
* Deadliner service
* Works.
* Uses helloworld.proto.
* Style fix
* Comments
* Uses Echo service and adds streaming example.
* Addresses the comments.
* Adds an error.
* Addresses PR comments.
* Removes port parameter from a function.
Possible settings of this environment variable:
- "hybrid" (default; removed after the 1.17 release): do not wait for handshake before considering a connection ready, but wait before considering successful.
- "on" (default after the 1.17 release): wait for handshake before considering a connection ready/successful.
- "off": do not wait for handshake before considering a connection ready/successful.
This setting will be completely removed after the 1.18 release, and "on" will be the only supported behavior.