Classes | Public Member Functions | Static Public Member Functions | Public Attributes | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
grpc_core::ClientChannel::LoadBalancedCall Class Reference

#include <client_channel.h>

Inheritance diagram for grpc_core::ClientChannel::LoadBalancedCall:
Inheritance graph
[legend]

Classes

class  BackendMetricAccessor
 
class  LbCallState
 
class  LbQueuedCallCanceller
 
class  Metadata
 

Public Member Functions

 LoadBalancedCall (ClientChannel *chand, const grpc_call_element_args &args, grpc_polling_entity *pollent, grpc_closure *on_call_destruction_complete, ConfigSelector::CallDispatchController *call_dispatch_controller, bool is_transparent_retry)
 
void Orphan () override
 
void StartTransportStreamOpBatch (grpc_transport_stream_op_batch *batch)
 
RefCountedPtr< SubchannelCallsubchannel_call () const
 
 ~LoadBalancedCall () override
 
- Public Member Functions inherited from grpc_core::InternallyRefCounted< LoadBalancedCall, kUnrefCallDtor >
 InternallyRefCounted (const InternallyRefCounted &)=delete
 
InternallyRefCountedoperator= (const InternallyRefCounted &)=delete
 
- Public Member Functions inherited from grpc_core::Orphanable
Orphanableoperator= (const Orphanable &)=delete
 
 Orphanable (const Orphanable &)=delete
 

Static Public Member Functions

static void PickSubchannel (void *arg, grpc_error_handle error)
 

Public Attributes

bool PickSubchannelLocked(grpc_error_handle *error) ABSL_EXCLUSIVE_LOCKS_REQUIRED(&ClientChannel voi AsyncPickDone )(grpc_error_handle error)
 

Private Types

typedef bool(* YieldCallCombinerPredicate) (const CallCombinerClosureList &closures)
 

Private Member Functions

void CreateSubchannelCall ()
 
void PendingBatchesAdd (grpc_transport_stream_op_batch *batch)
 
void PendingBatchesFail (grpc_error_handle error, YieldCallCombinerPredicate yield_call_combiner_predicate)
 
void PendingBatchesResume ()
 
void RecordCallCompletion (absl::Status status)
 

Static Private Member Functions

static void FailPendingBatchInCallCombiner (void *arg, grpc_error_handle error)
 
static size_t GetBatchIndex (grpc_transport_stream_op_batch *batch)
 
static bool NoYieldCallCombiner (const CallCombinerClosureList &)
 
static void PickDone (void *arg, grpc_error_handle error)
 
static void RecvInitialMetadataReady (void *arg, grpc_error_handle error)
 
static void RecvMessageReady (void *arg, grpc_error_handle error)
 
static void RecvTrailingMetadataReady (void *arg, grpc_error_handle error)
 
static void ResumePendingBatchInCallCombiner (void *arg, grpc_error_handle ignored)
 
static void SendInitialMetadataOnComplete (void *arg, grpc_error_handle error)
 
static bool YieldCallCombiner (const CallCombinerClosureList &)
 
static bool YieldCallCombinerIfPendingBatchesFound (const CallCombinerClosureList &closures)
 

Private Attributes

Arenaarena_
 
const BackendMetricDatabackend_metric_data_ = nullptr
 
CallTracer::CallAttemptTracercall_attempt_tracer_
 
CallCombinercall_combiner_
 
grpc_call_context_elementcall_context_
 
ConfigSelector::CallDispatchControllercall_dispatch_controller_
 
grpc_error_handle cancel_error_ = GRPC_ERROR_NONE
 
void MaybeRemoveCallFromLbQueuedCallsLocked() ABSL_EXCLUSIVE_LOCKS_REQUIRED(&ClientChannel void MaybeAddCallToLbQueuedCallsLocked() ABSL_EXCLUSIVE_LOCKS_REQUIRED(&ClientChannel ClientChannelchand_
 
RefCountedPtr< ConnectedSubchannelconnected_subchannel_
 
Timestamp deadline_
 
grpc_error_handle failure_error_ = GRPC_ERROR_NONE
 
gpr_cycle_counter lb_call_start_time_ = gpr_get_cycle_counter()
 
std::unique_ptr< LoadBalancingPolicy::SubchannelCallTrackerInterfacelb_subchannel_call_tracker_
 
grpc_closureon_call_destruction_complete_
 
grpc_closureoriginal_recv_initial_metadata_ready_ = nullptr
 
grpc_closureoriginal_recv_message_ready_ = nullptr
 
grpc_closureoriginal_recv_trailing_metadata_ready_ = nullptr
 
grpc_closureoriginal_send_initial_metadata_on_complete_ = nullptr
 
grpc_call_stackowning_call_
 
Slice path_
 
gpr_atmpeer_string_ = nullptr
 
grpc_transport_stream_op_batchpending_batches_ [MAX_PENDING_BATCHES] = {}
 
grpc_closure pick_closure_
 
grpc_polling_entitypollent_
 
grpc_metadata_batchrecv_initial_metadata_ = nullptr
 
grpc_closure recv_initial_metadata_ready_
 
absl::optional< SliceBuffer > * recv_message_ = nullptr
 
grpc_closure recv_message_ready_
 
grpc_metadata_batchrecv_trailing_metadata_ = nullptr
 
grpc_closure recv_trailing_metadata_ready_
 
grpc_closure send_initial_metadata_on_complete_
 
RefCountedPtr< SubchannelCallsubchannel_call_
 
grpc_transport_stream_statstransport_stream_stats_ = nullptr
 

Additional Inherited Members

- Protected Member Functions inherited from grpc_core::InternallyRefCounted< LoadBalancedCall, kUnrefCallDtor >
 InternallyRefCounted (const char *trace=nullptr, intptr_t initial_refcount=1)
 
RefCountedPtr< LoadBalancedCall > Ref () GRPC_MUST_USE_RESULT
 
RefCountedPtr< LoadBalancedCall > Ref (const DebugLocation &location, const char *reason) GRPC_MUST_USE_RESULT
 
void Unref ()
 
void Unref (const DebugLocation &location, const char *reason)
 
 ~InternallyRefCounted () override=default
 
- Protected Member Functions inherited from grpc_core::Orphanable
 Orphanable ()
 
virtual ~Orphanable ()
 

Detailed Description

Definition at line 384 of file client_channel.h.

Member Typedef Documentation

◆ YieldCallCombinerPredicate

typedef bool(* grpc_core::ClientChannel::LoadBalancedCall::YieldCallCombinerPredicate) (const CallCombinerClosureList &closures)
private

Definition at line 444 of file client_channel.h.

Constructor & Destructor Documentation

◆ LoadBalancedCall()

grpc_core::ClientChannel::LoadBalancedCall::LoadBalancedCall ( ClientChannel chand,
const grpc_call_element_args args,
grpc_polling_entity pollent,
grpc_closure on_call_destruction_complete,
ConfigSelector::CallDispatchController call_dispatch_controller,
bool  is_transparent_retry 
)

Definition at line 2608 of file client_channel.cc.

◆ ~LoadBalancedCall()

grpc_core::ClientChannel::LoadBalancedCall::~LoadBalancedCall ( )
override

Definition at line 2634 of file client_channel.cc.

Member Function Documentation

◆ CreateSubchannelCall()

void grpc_core::ClientChannel::LoadBalancedCall::CreateSubchannelCall ( )
private

Definition at line 3032 of file client_channel.cc.

◆ FailPendingBatchInCallCombiner()

void grpc_core::ClientChannel::LoadBalancedCall::FailPendingBatchInCallCombiner ( void *  arg,
grpc_error_handle  error 
)
staticprivate

Definition at line 2693 of file client_channel.cc.

◆ GetBatchIndex()

size_t grpc_core::ClientChannel::LoadBalancedCall::GetBatchIndex ( grpc_transport_stream_op_batch batch)
staticprivate

Definition at line 2666 of file client_channel.cc.

◆ NoYieldCallCombiner()

static bool grpc_core::ClientChannel::LoadBalancedCall::NoYieldCallCombiner ( const CallCombinerClosureList )
inlinestaticprivate

Definition at line 449 of file client_channel.h.

◆ Orphan()

void grpc_core::ClientChannel::LoadBalancedCall::Orphan ( )
overridevirtual

Implements grpc_core::Orphanable.

Definition at line 2650 of file client_channel.cc.

◆ PendingBatchesAdd()

void grpc_core::ClientChannel::LoadBalancedCall::PendingBatchesAdd ( grpc_transport_stream_op_batch batch)
private

Definition at line 2680 of file client_channel.cc.

◆ PendingBatchesFail()

void grpc_core::ClientChannel::LoadBalancedCall::PendingBatchesFail ( grpc_error_handle  error,
YieldCallCombinerPredicate  yield_call_combiner_predicate 
)
private

Definition at line 2704 of file client_channel.cc.

◆ PendingBatchesResume()

void grpc_core::ClientChannel::LoadBalancedCall::PendingBatchesResume ( )
private

Definition at line 2751 of file client_channel.cc.

◆ PickDone()

void grpc_core::ClientChannel::LoadBalancedCall::PickDone ( void *  arg,
grpc_error_handle  error 
)
staticprivate

Definition at line 3135 of file client_channel.cc.

◆ PickSubchannel()

void grpc_core::ClientChannel::LoadBalancedCall::PickSubchannel ( void *  arg,
grpc_error_handle  error 
)
static

Definition at line 3151 of file client_channel.cc.

◆ RecordCallCompletion()

void grpc_core::ClientChannel::LoadBalancedCall::RecordCallCompletion ( absl::Status  status)
private

Definition at line 3013 of file client_channel.cc.

◆ RecvInitialMetadataReady()

void grpc_core::ClientChannel::LoadBalancedCall::RecvInitialMetadataReady ( void *  arg,
grpc_error_handle  error 
)
staticprivate

Definition at line 2932 of file client_channel.cc.

◆ RecvMessageReady()

void grpc_core::ClientChannel::LoadBalancedCall::RecvMessageReady ( void *  arg,
grpc_error_handle  error 
)
staticprivate

Definition at line 2949 of file client_channel.cc.

◆ RecvTrailingMetadataReady()

void grpc_core::ClientChannel::LoadBalancedCall::RecvTrailingMetadataReady ( void *  arg,
grpc_error_handle  error 
)
staticprivate

Definition at line 2963 of file client_channel.cc.

◆ ResumePendingBatchInCallCombiner()

void grpc_core::ClientChannel::LoadBalancedCall::ResumePendingBatchInCallCombiner ( void *  arg,
grpc_error_handle  ignored 
)
staticprivate

Definition at line 2740 of file client_channel.cc.

◆ SendInitialMetadataOnComplete()

void grpc_core::ClientChannel::LoadBalancedCall::SendInitialMetadataOnComplete ( void *  arg,
grpc_error_handle  error 
)
staticprivate

Definition at line 2916 of file client_channel.cc.

◆ StartTransportStreamOpBatch()

void grpc_core::ClientChannel::LoadBalancedCall::StartTransportStreamOpBatch ( grpc_transport_stream_op_batch batch)

Definition at line 2779 of file client_channel.cc.

◆ subchannel_call()

RefCountedPtr<SubchannelCall> grpc_core::ClientChannel::LoadBalancedCall::subchannel_call ( ) const
inline

Definition at line 429 of file client_channel.h.

◆ YieldCallCombiner()

static bool grpc_core::ClientChannel::LoadBalancedCall::YieldCallCombiner ( const CallCombinerClosureList )
inlinestaticprivate

Definition at line 446 of file client_channel.h.

◆ YieldCallCombinerIfPendingBatchesFound()

static bool grpc_core::ClientChannel::LoadBalancedCall::YieldCallCombinerIfPendingBatchesFound ( const CallCombinerClosureList closures)
inlinestaticprivate

Definition at line 452 of file client_channel.h.

Member Data Documentation

◆ arena_

Arena* grpc_core::ClientChannel::LoadBalancedCall::arena_
private

Definition at line 491 of file client_channel.h.

◆ AsyncPickDone

void grpc_core::ClientChannel::LoadBalancedCall::AsyncPickDone

Definition at line 427 of file client_channel.h.

◆ backend_metric_data_

const BackendMetricData* grpc_core::ClientChannel::LoadBalancedCall::backend_metric_data_ = nullptr
private

Definition at line 520 of file client_channel.h.

◆ call_attempt_tracer_

CallTracer::CallAttemptTracer* grpc_core::ClientChannel::LoadBalancedCall::call_attempt_tracer_
private

Definition at line 499 of file client_channel.h.

◆ call_combiner_

CallCombiner* grpc_core::ClientChannel::LoadBalancedCall::call_combiner_
private

Definition at line 493 of file client_channel.h.

◆ call_context_

grpc_call_context_element* grpc_core::ClientChannel::LoadBalancedCall::call_context_
private

Definition at line 494 of file client_channel.h.

◆ call_dispatch_controller_

ConfigSelector::CallDispatchController* grpc_core::ClientChannel::LoadBalancedCall::call_dispatch_controller_
private

Definition at line 497 of file client_channel.h.

◆ cancel_error_

grpc_error_handle grpc_core::ClientChannel::LoadBalancedCall::cancel_error_ = GRPC_ERROR_NONE
private

Definition at line 504 of file client_channel.h.

◆ chand_

void MaybeRemoveCallFromLbQueuedCallsLocked () ABSL_EXCLUSIVE_LOCKS_REQUIRED( &ClientChannel void MaybeAddCallToLbQueuedCallsLocked () ABSL_EXCLUSIVE_LOCKS_REQUIRED( &ClientChannel ClientChannel* grpc_core::ClientChannel::LoadBalancedCall::chand_
private

Definition at line 481 of file client_channel.h.

◆ connected_subchannel_

RefCountedPtr<ConnectedSubchannel> grpc_core::ClientChannel::LoadBalancedCall::connected_subchannel_
private

Definition at line 519 of file client_channel.h.

◆ deadline_

Timestamp grpc_core::ClientChannel::LoadBalancedCall::deadline_
private

Definition at line 490 of file client_channel.h.

◆ failure_error_

grpc_error_handle grpc_core::ClientChannel::LoadBalancedCall::failure_error_ = GRPC_ERROR_NONE
private

Definition at line 507 of file client_channel.h.

◆ lb_call_start_time_

gpr_cycle_counter grpc_core::ClientChannel::LoadBalancedCall::lb_call_start_time_ = gpr_get_cycle_counter()
private

Definition at line 501 of file client_channel.h.

◆ lb_subchannel_call_tracker_

std::unique_ptr<LoadBalancingPolicy::SubchannelCallTrackerInterface> grpc_core::ClientChannel::LoadBalancedCall::lb_subchannel_call_tracker_
private

Definition at line 522 of file client_channel.h.

◆ on_call_destruction_complete_

grpc_closure* grpc_core::ClientChannel::LoadBalancedCall::on_call_destruction_complete_
private

Definition at line 496 of file client_channel.h.

◆ original_recv_initial_metadata_ready_

grpc_closure* grpc_core::ClientChannel::LoadBalancedCall::original_recv_initial_metadata_ready_ = nullptr
private

Definition at line 534 of file client_channel.h.

◆ original_recv_message_ready_

grpc_closure* grpc_core::ClientChannel::LoadBalancedCall::original_recv_message_ready_ = nullptr
private

Definition at line 539 of file client_channel.h.

◆ original_recv_trailing_metadata_ready_

grpc_closure* grpc_core::ClientChannel::LoadBalancedCall::original_recv_trailing_metadata_ready_ = nullptr
private

Definition at line 545 of file client_channel.h.

◆ original_send_initial_metadata_on_complete_

grpc_closure* grpc_core::ClientChannel::LoadBalancedCall::original_send_initial_metadata_on_complete_ = nullptr
private

Definition at line 529 of file client_channel.h.

◆ owning_call_

grpc_call_stack* grpc_core::ClientChannel::LoadBalancedCall::owning_call_
private

Definition at line 492 of file client_channel.h.

◆ path_

Slice grpc_core::ClientChannel::LoadBalancedCall::path_
private

Definition at line 489 of file client_channel.h.

◆ peer_string_

gpr_atm* grpc_core::ClientChannel::LoadBalancedCall::peer_string_ = nullptr
private

Definition at line 527 of file client_channel.h.

◆ pending_batches_

grpc_transport_stream_op_batch* grpc_core::ClientChannel::LoadBalancedCall::pending_batches_[MAX_PENDING_BATCHES] = {}
private

Definition at line 552 of file client_channel.h.

◆ pick_closure_

grpc_closure grpc_core::ClientChannel::LoadBalancedCall::pick_closure_
private

Definition at line 509 of file client_channel.h.

◆ pollent_

grpc_polling_entity* grpc_core::ClientChannel::LoadBalancedCall::pollent_
private

Definition at line 495 of file client_channel.h.

◆ recv_initial_metadata_

grpc_metadata_batch* grpc_core::ClientChannel::LoadBalancedCall::recv_initial_metadata_ = nullptr
private

Definition at line 532 of file client_channel.h.

◆ recv_initial_metadata_ready_

grpc_closure grpc_core::ClientChannel::LoadBalancedCall::recv_initial_metadata_ready_
private

Definition at line 533 of file client_channel.h.

◆ recv_message_

absl::optional<SliceBuffer>* grpc_core::ClientChannel::LoadBalancedCall::recv_message_ = nullptr
private

Definition at line 537 of file client_channel.h.

◆ recv_message_ready_

grpc_closure grpc_core::ClientChannel::LoadBalancedCall::recv_message_ready_
private

Definition at line 538 of file client_channel.h.

◆ recv_trailing_metadata_

grpc_metadata_batch* grpc_core::ClientChannel::LoadBalancedCall::recv_trailing_metadata_ = nullptr
private

Definition at line 542 of file client_channel.h.

◆ recv_trailing_metadata_ready_

grpc_closure grpc_core::ClientChannel::LoadBalancedCall::recv_trailing_metadata_ready_
private

Definition at line 544 of file client_channel.h.

◆ send_initial_metadata_on_complete_

grpc_closure grpc_core::ClientChannel::LoadBalancedCall::send_initial_metadata_on_complete_
private

Definition at line 528 of file client_channel.h.

◆ subchannel_call_

RefCountedPtr<SubchannelCall> grpc_core::ClientChannel::LoadBalancedCall::subchannel_call_
private

Definition at line 524 of file client_channel.h.

◆ transport_stream_stats_

grpc_transport_stream_stats* grpc_core::ClientChannel::LoadBalancedCall::transport_stream_stats_ = nullptr
private

Definition at line 543 of file client_channel.h.


The documentation for this class was generated from the following files:


grpc
Author(s):
autogenerated on Fri May 16 2025 03:03:35