api,stub: Improve waitForReady documentation

This commit is contained in:
Eric Anderson 2020-04-30 15:30:24 -07:00 committed by Eric Anderson
parent c6251cf085
commit 4674b27736
2 changed files with 10 additions and 3 deletions

View File

@ -150,8 +150,10 @@ public final class CallOptions {
/** /**
* Enables <a href="https://github.com/grpc/grpc/blob/master/doc/wait-for-ready.md"> * Enables <a href="https://github.com/grpc/grpc/blob/master/doc/wait-for-ready.md">
* 'wait for ready'</a> feature for the call. 'Fail fast' is the default option for gRPC calls * 'wait for ready'</a> for the call. Wait-for-ready queues the RPC until a connection is
* and 'wait for ready' is the opposite to it. * available. This may dramatically increase the latency of the RPC, but avoids failing
* "unnecessarily." The default queues the RPC until an attempt to connect has completed, but
* fails RPCs without sending them if unable to connect.
*/ */
public CallOptions withWaitForReady() { public CallOptions withWaitForReady() {
CallOptions newOptions = new CallOptions(this); CallOptions newOptions = new CallOptions(this);

View File

@ -220,7 +220,12 @@ public abstract class AbstractStub<S extends AbstractStub<S>> {
} }
/** /**
* Returns a new stub that uses the 'wait for ready' call option. * Returns a new stub that uses
* <a href="https://github.com/grpc/grpc/blob/master/doc/wait-for-ready.md">'wait for ready'</a>
* for the call. Wait-for-ready queues the RPC until a connection is available. This may
* dramatically increase the latency of the RPC, but avoids failing "unnecessarily." The default
* queues the RPC until an attempt to connect has completed, but fails RPCs without sending them
* if unable to connect.
* *
* @since 1.1.0 * @since 1.1.0
*/ */