Documentation ¶
Overview ¶
Package grpcutil contains gRPC utilities useful to binding implementations.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WithDefaultTimeout ¶
func WithDefaultTimeout(ctx context.Context, timeout time.Duration) (context.Context, context.CancelFunc)
WithDefaultTimeout returns context.WithTimeout(ctx, timeout) if ctx has no deadline; otherwise returns the context as-is and an empty cancel function.
func WithStreamDefaultTimeout ¶
func WithStreamDefaultTimeout(timeout time.Duration) grpc.DialOption
WithStreamDefaultTimeout returns a dial option that intercepts stream requests and imposes the specified context timeout on the request if it does not already have a deadline.
func WithUnaryDefaultTimeout ¶
func WithUnaryDefaultTimeout(timeout time.Duration) grpc.DialOption
WithUnaryDefaultTimeout returns a dial option that intercepts unary requests and imposes the specified context timeout on the request if it does not already have a deadline.
Types ¶
This section is empty.
Directories ¶
Path | Synopsis |
---|---|
Package testservice provides an interface for testing with the Test service.
|
Package testservice provides an interface for testing with the Test service. |
Click to show internal directories.
Click to hide internal directories.