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

Struct rpcBehaviorPicker

interop/xds/custom_lb.go:120–123  ·  view source on GitHub ↗

rpcBehaviorPicker wraps a picker and adds the rpc-behavior metadata field into the child pick result's metadata.

Source from the content-addressed store, hash-verified

118// rpcBehaviorPicker wraps a picker and adds the rpc-behavior metadata field
119// into the child pick result's metadata.
120type rpcBehaviorPicker struct {
121 childPicker balancer.Picker
122 rpcBehavior string
123}
124
125// Pick appends the rpc-behavior metadata entry to the pick result of the child.
126func (p *rpcBehaviorPicker) Pick(info balancer.PickInfo) (balancer.PickResult, error) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected