NVIDIA DeepStream SDK API Reference

9.2 Release
exporter::otlp::OtlpGrpcClient Class Reference

Detailed Description

The OTLP gRPC client contains utility functions of gRPC.

Definition at line 105 of file includes/opentelemetry/exporters/otlp/otlp_grpc_client.h.

Public Member Functions

 OtlpGrpcClient (const OtlpGrpcClientOptions &options)
 
 ~OtlpGrpcClient ()
 
 OtlpGrpcClient (const OtlpGrpcClient &)=delete
 
 OtlpGrpcClient (OtlpGrpcClient &&)=delete
 
OtlpGrpcClient & operator= (const OtlpGrpcClient &)=delete
 
OtlpGrpcClient & operator= (OtlpGrpcClient &&)=delete
 
std::unique_ptr< proto::collector::trace::v1::TraceService::StubInterface > MakeTraceServiceStub ()
 Create trace service stub to communicate with the OpenTelemetry Collector. More...
 
std::unique_ptr< proto::collector::metrics::v1::MetricsService::StubInterface > MakeMetricsServiceStub ()
 Create metrics service stub to communicate with the OpenTelemetry Collector. More...
 
std::unique_ptr< proto::collector::logs::v1::LogsService::StubInterface > MakeLogsServiceStub ()
 Create logs service stub to communicate with the OpenTelemetry Collector. More...
 
void AddReference (OtlpGrpcClientReferenceGuard &guard, const OtlpGrpcClientOptions &options) noexcept
 
bool RemoveReference (OtlpGrpcClientReferenceGuard &guard) noexcept
 Reomve reference fro a guard object. More...
 
bool ForceFlush (std::chrono::microseconds timeout=(std::chrono::microseconds::max)()) noexcept
 Force flush the gRPC client. More...
 
bool Shutdown (OtlpGrpcClientReferenceGuard &guard, std::chrono::microseconds timeout=std::chrono::microseconds(0)) noexcept
 Shut down the gRPC client. More...
 
std::shared_ptr< OtlpGrpcClientAsyncData > MutableAsyncData (const OtlpGrpcClientOptions &options)
 
bool IsShutdown () const noexcept
 
 OtlpGrpcClient (const OtlpGrpcClientOptions &options)
 
 ~OtlpGrpcClient ()
 
 OtlpGrpcClient (const OtlpGrpcClient &)=delete
 
 OtlpGrpcClient (OtlpGrpcClient &&)=delete
 
OtlpGrpcClient & operator= (const OtlpGrpcClient &)=delete
 
OtlpGrpcClient & operator= (OtlpGrpcClient &&)=delete
 
std::unique_ptr< proto::collector::trace::v1::TraceService::StubInterface > MakeTraceServiceStub ()
 Create trace service stub to communicate with the OpenTelemetry Collector. More...
 
std::unique_ptr< proto::collector::metrics::v1::MetricsService::StubInterface > MakeMetricsServiceStub ()
 Create metrics service stub to communicate with the OpenTelemetry Collector. More...
 
std::unique_ptr< proto::collector::logs::v1::LogsService::StubInterface > MakeLogsServiceStub ()
 Create logs service stub to communicate with the OpenTelemetry Collector. More...
 
void AddReference (OtlpGrpcClientReferenceGuard &guard, const OtlpGrpcClientOptions &options) noexcept
 
bool RemoveReference (OtlpGrpcClientReferenceGuard &guard) noexcept
 Reomve reference fro a guard object. More...
 
bool ForceFlush (std::chrono::microseconds timeout=(std::chrono::microseconds::max)()) noexcept
 Force flush the gRPC client. More...
 
bool Shutdown (OtlpGrpcClientReferenceGuard &guard, std::chrono::microseconds timeout=std::chrono::microseconds(0)) noexcept
 Shut down the gRPC client. More...
 
std::shared_ptr< OtlpGrpcClientAsyncData > MutableAsyncData (const OtlpGrpcClientOptions &options)
 
bool IsShutdown () const noexcept
 

Static Public Member Functions

static std::string GetGrpcTarget (const std::string &endpoint)
 
static std::shared_ptr< grpc::Channel > MakeChannel (const OtlpGrpcClientOptions &options)
 Create gRPC channel from the exporter options. More...
 
static std::unique_ptr< grpc::ClientContext > MakeClientContext (const OtlpGrpcClientOptions &options)
 Create gRPC client context to call RPC. More...
 
static grpc::Status DelegateExport (proto::collector::trace::v1::TraceService::StubInterface *stub, std::unique_ptr< grpc::ClientContext > &&context, std::unique_ptr< google::protobuf::Arena > &&arena, proto::collector::trace::v1::ExportTraceServiceRequest &&request, proto::collector::trace::v1::ExportTraceServiceResponse *response)
 
static grpc::Status DelegateExport (proto::collector::metrics::v1::MetricsService::StubInterface *stub, std::unique_ptr< grpc::ClientContext > &&context, std::unique_ptr< google::protobuf::Arena > &&arena, proto::collector::metrics::v1::ExportMetricsServiceRequest &&request, proto::collector::metrics::v1::ExportMetricsServiceResponse *response)
 
static grpc::Status DelegateExport (proto::collector::logs::v1::LogsService::StubInterface *stub, std::unique_ptr< grpc::ClientContext > &&context, std::unique_ptr< google::protobuf::Arena > &&arena, proto::collector::logs::v1::ExportLogsServiceRequest &&request, proto::collector::logs::v1::ExportLogsServiceResponse *response)
 
static std::string GetGrpcTarget (const std::string &endpoint)
 
static std::shared_ptr< grpc::Channel > MakeChannel (const OtlpGrpcClientOptions &options)
 Create gRPC channel from the exporter options. More...
 
static std::unique_ptr< grpc::ClientContext > MakeClientContext (const OtlpGrpcClientOptions &options)
 Create gRPC client context to call RPC. More...
 
static grpc::Status DelegateExport (proto::collector::trace::v1::TraceService::StubInterface *stub, std::unique_ptr< grpc::ClientContext > &&context, std::unique_ptr< google::protobuf::Arena > &&arena, proto::collector::trace::v1::ExportTraceServiceRequest &&request, proto::collector::trace::v1::ExportTraceServiceResponse *response)
 
static grpc::Status DelegateExport (proto::collector::metrics::v1::MetricsService::StubInterface *stub, std::unique_ptr< grpc::ClientContext > &&context, std::unique_ptr< google::protobuf::Arena > &&arena, proto::collector::metrics::v1::ExportMetricsServiceRequest &&request, proto::collector::metrics::v1::ExportMetricsServiceResponse *response)
 
static grpc::Status DelegateExport (proto::collector::logs::v1::LogsService::StubInterface *stub, std::unique_ptr< grpc::ClientContext > &&context, std::unique_ptr< google::protobuf::Arena > &&arena, proto::collector::logs::v1::ExportLogsServiceRequest &&request, proto::collector::logs::v1::ExportLogsServiceResponse *response)
 

Constructor & Destructor Documentation

◆ OtlpGrpcClient() [1/6]

exporter::otlp::OtlpGrpcClient::OtlpGrpcClient ( const OtlpGrpcClientOptions &  options)

◆ ~OtlpGrpcClient() [1/2]

exporter::otlp::OtlpGrpcClient::~OtlpGrpcClient ( )

◆ OtlpGrpcClient() [2/6]

exporter::otlp::OtlpGrpcClient::OtlpGrpcClient ( const OtlpGrpcClient &  )
delete

◆ OtlpGrpcClient() [3/6]

exporter::otlp::OtlpGrpcClient::OtlpGrpcClient ( OtlpGrpcClient &&  )
delete

◆ OtlpGrpcClient() [4/6]

exporter::otlp::OtlpGrpcClient::OtlpGrpcClient ( const OtlpGrpcClientOptions &  options)

◆ ~OtlpGrpcClient() [2/2]

exporter::otlp::OtlpGrpcClient::~OtlpGrpcClient ( )

◆ OtlpGrpcClient() [5/6]

exporter::otlp::OtlpGrpcClient::OtlpGrpcClient ( const OtlpGrpcClient &  )
delete

◆ OtlpGrpcClient() [6/6]

exporter::otlp::OtlpGrpcClient::OtlpGrpcClient ( OtlpGrpcClient &&  )
delete

Member Function Documentation

◆ AddReference() [1/2]

void exporter::otlp::OtlpGrpcClient::AddReference ( OtlpGrpcClientReferenceGuard &  guard,
const OtlpGrpcClientOptions &  options 
)
noexcept

◆ AddReference() [2/2]

void exporter::otlp::OtlpGrpcClient::AddReference ( OtlpGrpcClientReferenceGuard &  guard,
const OtlpGrpcClientOptions &  options 
)
noexcept

◆ DelegateExport() [1/6]

static grpc::Status exporter::otlp::OtlpGrpcClient::DelegateExport ( proto::collector::logs::v1::LogsService::StubInterface *  stub,
std::unique_ptr< grpc::ClientContext > &&  context,
std::unique_ptr< google::protobuf::Arena > &&  arena,
proto::collector::logs::v1::ExportLogsServiceRequest &&  request,
proto::collector::logs::v1::ExportLogsServiceResponse *  response 
)
static

◆ DelegateExport() [2/6]

static grpc::Status exporter::otlp::OtlpGrpcClient::DelegateExport ( proto::collector::logs::v1::LogsService::StubInterface *  stub,
std::unique_ptr< grpc::ClientContext > &&  context,
std::unique_ptr< google::protobuf::Arena > &&  arena,
proto::collector::logs::v1::ExportLogsServiceRequest &&  request,
proto::collector::logs::v1::ExportLogsServiceResponse *  response 
)
static

◆ DelegateExport() [3/6]

static grpc::Status exporter::otlp::OtlpGrpcClient::DelegateExport ( proto::collector::metrics::v1::MetricsService::StubInterface *  stub,
std::unique_ptr< grpc::ClientContext > &&  context,
std::unique_ptr< google::protobuf::Arena > &&  arena,
proto::collector::metrics::v1::ExportMetricsServiceRequest &&  request,
proto::collector::metrics::v1::ExportMetricsServiceResponse *  response 
)
static

◆ DelegateExport() [4/6]

static grpc::Status exporter::otlp::OtlpGrpcClient::DelegateExport ( proto::collector::metrics::v1::MetricsService::StubInterface *  stub,
std::unique_ptr< grpc::ClientContext > &&  context,
std::unique_ptr< google::protobuf::Arena > &&  arena,
proto::collector::metrics::v1::ExportMetricsServiceRequest &&  request,
proto::collector::metrics::v1::ExportMetricsServiceResponse *  response 
)
static

◆ DelegateExport() [5/6]

static grpc::Status exporter::otlp::OtlpGrpcClient::DelegateExport ( proto::collector::trace::v1::TraceService::StubInterface *  stub,
std::unique_ptr< grpc::ClientContext > &&  context,
std::unique_ptr< google::protobuf::Arena > &&  arena,
proto::collector::trace::v1::ExportTraceServiceRequest &&  request,
proto::collector::trace::v1::ExportTraceServiceResponse *  response 
)
static

◆ DelegateExport() [6/6]

static grpc::Status exporter::otlp::OtlpGrpcClient::DelegateExport ( proto::collector::trace::v1::TraceService::StubInterface *  stub,
std::unique_ptr< grpc::ClientContext > &&  context,
std::unique_ptr< google::protobuf::Arena > &&  arena,
proto::collector::trace::v1::ExportTraceServiceRequest &&  request,
proto::collector::trace::v1::ExportTraceServiceResponse *  response 
)
static

◆ ForceFlush() [1/2]

bool exporter::otlp::OtlpGrpcClient::ForceFlush ( std::chrono::microseconds  timeout = (std::chrono::microseconds::max)())
noexcept

Force flush the gRPC client.

◆ ForceFlush() [2/2]

bool exporter::otlp::OtlpGrpcClient::ForceFlush ( std::chrono::microseconds  timeout = (std::chrono::microseconds::max)())
noexcept

Force flush the gRPC client.

◆ GetGrpcTarget() [1/2]

static std::string exporter::otlp::OtlpGrpcClient::GetGrpcTarget ( const std::string &  endpoint)
static

◆ GetGrpcTarget() [2/2]

static std::string exporter::otlp::OtlpGrpcClient::GetGrpcTarget ( const std::string &  endpoint)
static

◆ IsShutdown() [1/2]

bool exporter::otlp::OtlpGrpcClient::IsShutdown ( ) const
noexcept

◆ IsShutdown() [2/2]

bool exporter::otlp::OtlpGrpcClient::IsShutdown ( ) const
noexcept

◆ MakeChannel() [1/2]

static std::shared_ptr<grpc::Channel> exporter::otlp::OtlpGrpcClient::MakeChannel ( const OtlpGrpcClientOptions &  options)
static

Create gRPC channel from the exporter options.

◆ MakeChannel() [2/2]

static std::shared_ptr<grpc::Channel> exporter::otlp::OtlpGrpcClient::MakeChannel ( const OtlpGrpcClientOptions &  options)
static

Create gRPC channel from the exporter options.

◆ MakeClientContext() [1/2]

static std::unique_ptr<grpc::ClientContext> exporter::otlp::OtlpGrpcClient::MakeClientContext ( const OtlpGrpcClientOptions &  options)
static

Create gRPC client context to call RPC.

◆ MakeClientContext() [2/2]

static std::unique_ptr<grpc::ClientContext> exporter::otlp::OtlpGrpcClient::MakeClientContext ( const OtlpGrpcClientOptions &  options)
static

Create gRPC client context to call RPC.

◆ MakeLogsServiceStub() [1/2]

std::unique_ptr<proto::collector::logs::v1::LogsService::StubInterface> exporter::otlp::OtlpGrpcClient::MakeLogsServiceStub ( )

Create logs service stub to communicate with the OpenTelemetry Collector.

◆ MakeLogsServiceStub() [2/2]

std::unique_ptr<proto::collector::logs::v1::LogsService::StubInterface> exporter::otlp::OtlpGrpcClient::MakeLogsServiceStub ( )

Create logs service stub to communicate with the OpenTelemetry Collector.

◆ MakeMetricsServiceStub() [1/2]

std::unique_ptr<proto::collector::metrics::v1::MetricsService::StubInterface> exporter::otlp::OtlpGrpcClient::MakeMetricsServiceStub ( )

Create metrics service stub to communicate with the OpenTelemetry Collector.

◆ MakeMetricsServiceStub() [2/2]

std::unique_ptr<proto::collector::metrics::v1::MetricsService::StubInterface> exporter::otlp::OtlpGrpcClient::MakeMetricsServiceStub ( )

Create metrics service stub to communicate with the OpenTelemetry Collector.

◆ MakeTraceServiceStub() [1/2]

std::unique_ptr<proto::collector::trace::v1::TraceService::StubInterface> exporter::otlp::OtlpGrpcClient::MakeTraceServiceStub ( )

Create trace service stub to communicate with the OpenTelemetry Collector.

◆ MakeTraceServiceStub() [2/2]

std::unique_ptr<proto::collector::trace::v1::TraceService::StubInterface> exporter::otlp::OtlpGrpcClient::MakeTraceServiceStub ( )

Create trace service stub to communicate with the OpenTelemetry Collector.

◆ MutableAsyncData() [1/2]

std::shared_ptr<OtlpGrpcClientAsyncData> exporter::otlp::OtlpGrpcClient::MutableAsyncData ( const OtlpGrpcClientOptions &  options)

◆ MutableAsyncData() [2/2]

std::shared_ptr<OtlpGrpcClientAsyncData> exporter::otlp::OtlpGrpcClient::MutableAsyncData ( const OtlpGrpcClientOptions &  options)

◆ operator=() [1/4]

OtlpGrpcClient& exporter::otlp::OtlpGrpcClient::operator= ( const OtlpGrpcClient &  )
delete

◆ operator=() [2/4]

OtlpGrpcClient& exporter::otlp::OtlpGrpcClient::operator= ( const OtlpGrpcClient &  )
delete

◆ operator=() [3/4]

OtlpGrpcClient& exporter::otlp::OtlpGrpcClient::operator= ( OtlpGrpcClient &&  )
delete

◆ operator=() [4/4]

OtlpGrpcClient& exporter::otlp::OtlpGrpcClient::operator= ( OtlpGrpcClient &&  )
delete

◆ RemoveReference() [1/2]

bool exporter::otlp::OtlpGrpcClient::RemoveReference ( OtlpGrpcClientReferenceGuard &  guard)
noexcept

Reomve reference fro a guard object.

Parameters
guardguard object to remove reference from
Returns
true if there is no more reference to this gRPC client

◆ RemoveReference() [2/2]

bool exporter::otlp::OtlpGrpcClient::RemoveReference ( OtlpGrpcClientReferenceGuard &  guard)
noexcept

Reomve reference fro a guard object.

Parameters
guardguard object to remove reference from
Returns
true if there is no more reference to this gRPC client

◆ Shutdown() [1/2]

bool exporter::otlp::OtlpGrpcClient::Shutdown ( OtlpGrpcClientReferenceGuard &  guard,
std::chrono::microseconds  timeout = std::chrono::microseconds(0) 
)
noexcept

Shut down the gRPC client.

Parameters
timeoutan optional timeout, the default timeout of 0 means that no timeout is applied.
Returns
return the status of this operation

◆ Shutdown() [2/2]

bool exporter::otlp::OtlpGrpcClient::Shutdown ( OtlpGrpcClientReferenceGuard &  guard,
std::chrono::microseconds  timeout = std::chrono::microseconds(0) 
)
noexcept

Shut down the gRPC client.

Parameters
timeoutan optional timeout, the default timeout of 0 means that no timeout is applied.
Returns
return the status of this operation

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