GRPC C++
1.39.1
|
The result of picking a subchannel for a call. More...
#include <lb_policy.h>
Public Types | |
enum | ResultType { PICK_COMPLETE , PICK_QUEUE , PICK_FAILED } |
Data Fields | |
ResultType | type |
RefCountedPtr< SubchannelInterface > | subchannel |
Used only if type is PICK_COMPLETE. More... | |
grpc_error_handle | error = GRPC_ERROR_NONE |
Used only if type is PICK_FAILED. More... | |
std::function< void(grpc_error_handle, MetadataInterface *, CallState *)> | recv_trailing_metadata_ready |
Used only if type is PICK_COMPLETE. More... | |
The result of picking a subchannel for a call.
grpc_error_handle grpc_core::LoadBalancingPolicy::PickResult::error = GRPC_ERROR_NONE |
Used only if type is PICK_FAILED.
Error to be set when returning a failure.
std::function<void(grpc_error_handle, MetadataInterface*, CallState*)> grpc_core::LoadBalancingPolicy::PickResult::recv_trailing_metadata_ready |
Used only if type is PICK_COMPLETE.
Callback set by LB policy to be notified of trailing metadata. If set by LB policy, the client channel will invoke the callback when trailing metadata is returned. The metadata may be modified by the callback. However, the callback does not take ownership, so any data that needs to be used after returning must be copied. The call state can be used to obtain backend metric data.
RefCountedPtr<SubchannelInterface> grpc_core::LoadBalancingPolicy::PickResult::subchannel |
Used only if type is PICK_COMPLETE.
Will be set to the selected subchannel, or nullptr if the LB policy decides to drop the call.
ResultType grpc_core::LoadBalancingPolicy::PickResult::type |