mirror of https://github.com/grpc/grpc-go.git
godoc: clarify WithTimeout deprecation note (#3226)
Tell people to replace Dial + WithTimeout with DialContext + context.WithTimeout.
This commit is contained in:
parent
cb0e11b54f
commit
032a3799b2
|
|
@ -346,8 +346,8 @@ func WithCredentialsBundle(b credentials.Bundle) DialOption {
|
|||
// WithTimeout returns a DialOption that configures a timeout for dialing a
|
||||
// ClientConn initially. This is valid if and only if WithBlock() is present.
|
||||
//
|
||||
// Deprecated: use DialContext and context.WithTimeout instead. Will be
|
||||
// supported throughout 1.x.
|
||||
// Deprecated: use DialContext instead of Dial and context.WithTimeout
|
||||
// instead. Will be supported throughout 1.x.
|
||||
func WithTimeout(d time.Duration) DialOption {
|
||||
return newFuncDialOption(func(o *dialOptions) {
|
||||
o.timeout = d
|
||||
|
|
|
|||
Loading…
Reference in New Issue