Documentation
¶
Index ¶
- Variables
- func ClientOptions() []option.ClientOption
- func GRPCDialOptions() []grpc.DialOption
- func GRPCOptions(delegate url.URL) (string, []grpc.DialOption)
- func LoopbackDialOptions() []grpc.DialOption
- func RegisterListenerForTest(listener DialableListener) string
- func UnregisterTestListener(scheme string)
- type DialableListener
Constants ¶
This section is empty.
Variables ¶
var ( RecvMsgSize = 100 * 1024 * 1024 // 100MB SendMsgSize = 100 * 1024 * 1024 // 100MB )
These are defined as global variables, so that folks can expose them as flags in their entrypoints, if they choose.
Functions ¶
func ClientOptions ¶ added in v0.17.9
func ClientOptions() []option.ClientOption
ClientOptions wraps GRPCDialOptions as google.golang.org/api/option.ClientOption for use with Google API clients.
func GRPCDialOptions ¶ added in v0.17.9
func GRPCDialOptions() []grpc.DialOption
GRPCDialOptions returns the standard set of gRPC dial options for production use, including OTEL tracing, Prometheus client metrics, client identity propagation, and retry support.
func GRPCOptions ¶
func GRPCOptions(delegate url.URL) (string, []grpc.DialOption)
GRPCOptions returns a target address and dial options appropriate for the given URL scheme (http, https, bufnet, or registered test listeners).
func LoopbackDialOptions ¶ added in v0.17.16
func LoopbackDialOptions() []grpc.DialOption
LoopbackDialOptions returns a minimal set of dial options suitable for grpc-gateway loopback connections. It includes the clientid interceptor (so the server sees who originated the REST call) but omits client-side Prometheus metrics, OTEL tracing, and retries which would double-count or create noisy self-referential telemetry.
func RegisterListenerForTest ¶ added in v0.4.0
func RegisterListenerForTest(listener DialableListener) string
Register a test listener and get a provided scheme.
func UnregisterTestListener ¶ added in v0.4.0
func UnregisterTestListener(scheme string)
Unregister a test listener.
Types ¶
type DialableListener ¶ added in v0.4.0
var ListenerForTest DialableListener
ListenerForTest is to support bufnet in our testing.