Go to the documentation of this file.
19 #ifndef GRPC_SRC_CPP_SERVER_LOAD_REPORTER_ASYNC_SERVICE_IMPL_H
20 #define GRPC_SRC_CPP_SERVER_LOAD_REPORTER_ASYNC_SERVICE_IMPL_H
41 #include "src/proto/grpc/lb/v1/load_reporter.grpc.pb.h"
42 #include "src/proto/grpc/lb/v1/load_reporter.pb.h"
45 namespace load_reporter {
52 :
public grpc::lb::v1::LoadReporter::AsyncService {
55 std::unique_ptr<ServerCompletionQueue>
cq);
84 std::shared_ptr<ReportLoadHandler>
handler)
133 void OnReadDone(std::shared_ptr<ReportLoadHandler>
self,
bool ok);
138 void SendReport(std::shared_ptr<ReportLoadHandler>
self,
bool ok);
142 void OnFinishDone(std::shared_ptr<ReportLoadHandler>
self,
bool ok);
147 void Shutdown(std::shared_ptr<ReportLoadHandler>
self,
const char* reason);
164 grpc::lb::v1::LoadReportRequest>
194 std::unique_ptr<ServerCompletionQueue>
cq_;
207 #endif // GRPC_SRC_CPP_SERVER_LOAD_REPORTER_ASYNC_SERVICE_IMPL_H
grpc_core::Mutex cq_shutdown_mu_
std::unique_ptr< Alarm > next_report_alarm_
grpc::lb::v1::LoadReportRequest request_
void OnDoneNotified(std::shared_ptr< ReportLoadHandler > self, bool ok)
CallableTag on_done_notified_
ReportLoadHandler(ServerCompletionQueue *cq, LoadReporterAsyncServiceImpl *service, LoadReporter *load_reporter)
void ScheduleNextFetchAndSample()
enum grpc::load_reporter::LoadReporterAsyncServiceImpl::ReportLoadHandler::CallStatus call_status_
std::function< void(std::shared_ptr< ReportLoadHandler >, bool)> HandlerFunction
LoadReporter * load_reporter_
uint64_t load_report_interval_ms_
@ INITIAL_REQUEST_RECEIVED
ServerAsyncReaderWriter< grpc::lb::v1::LoadReportResponse, grpc::lb::v1::LoadReportRequest > stream_
~LoadReporterAsyncServiceImpl() override
CallableTag on_finish_done_
constexpr absl::remove_reference_t< T > && move(T &&t) noexcept
CallableTag next_inbound_
HandlerFunction handler_function_
static void Work(void *arg)
void Shutdown(std::shared_ptr< ReportLoadHandler > self, const char *reason)
void OnReadDone(std::shared_ptr< ReportLoadHandler > self, bool ok)
unsigned __int64 uint64_t
void SendReport(std::shared_ptr< ReportLoadHandler > self, bool ok)
std::shared_ptr< ReportLoadHandler > ReleaseHandler()
ServerCompletionQueue * cq_
std::unique_ptr< Alarm > next_fetch_and_sample_alarm_
CallableTag(HandlerFunction func, std::shared_ptr< ReportLoadHandler > handler)
void FetchAndSample(bool ok)
std::string load_balanced_hostname_
void OnFinishDone(std::shared_ptr< ReportLoadHandler > self, bool ok)
void ScheduleNextReport(std::shared_ptr< ReportLoadHandler > self, bool ok)
static void CreateAndStart(ServerCompletionQueue *cq, LoadReporterAsyncServiceImpl *service, LoadReporter *load_reporter)
std::shared_ptr< ReportLoadHandler > handler_
LoadReporterAsyncServiceImpl(std::unique_ptr< ServerCompletionQueue > cq)
LoadReporterAsyncServiceImpl & operator=(const LoadReporterAsyncServiceImpl &)=delete
std::unique_ptr< grpc_core::Thread > thread_
CallableTag next_outbound_
std::unique_ptr< LoadReporter > load_reporter_
__attribute__((deprecated("Please use GRPCProtoMethod."))) @interface ProtoMethod NSString * service
LoadReporterAsyncServiceImpl * service_
std::unique_ptr< ServerCompletionQueue > cq_
void OnRequestDelivered(std::shared_ptr< ReportLoadHandler > self, bool ok)
std::atomic_bool shutdown_
static grpc_completion_queue * cq
grpc
Author(s):
autogenerated on Thu Mar 13 2025 03:00:29