MCPcopy
hub / github.com/grpc/grpc-go / newLBBuilderWithFallbackTimeout

Function newLBBuilderWithFallbackTimeout

balancer/grpclb/grpclb.go:121–125  ·  view source on GitHub ↗

newLBBuilderWithFallbackTimeout creates a grpclb builder with the given fallbackTimeout. If no response is received from the remote balancer within fallbackTimeout, the backend addresses from the resolved address list will be used. Only call this function when a non-default fallback timeout is need

(fallbackTimeout time.Duration)

Source from the content-addressed store, hash-verified

119//
120// Only call this function when a non-default fallback timeout is needed.
121func newLBBuilderWithFallbackTimeout(fallbackTimeout time.Duration) balancer.Builder {
122 return &lbBuilder{
123 fallbackTimeout: fallbackTimeout,
124 }
125}
126
127type lbBuilder struct {
128 fallbackTimeout time.Duration

Callers 2

newLBBuilderFunction · 0.85
TestGRPCLB_FallbackMethod · 0.85

Calls

no outgoing calls

Tested by 1

TestGRPCLB_FallbackMethod · 0.68