NVIDIA DeepStream SDK API Reference

9.2 Release
exporter::otlp::OtlpHttpClient Class Reference

Detailed Description

The OTLP HTTP client exports span data in OpenTelemetry Protocol (OTLP) format.

Definition at line 153 of file includes/opentelemetry/exporters/otlp/otlp_http_client.h.

Public Member Functions

 OtlpHttpClient (OtlpHttpClientOptions &&options)
 Create an OtlpHttpClient using the given options. More...
 
 ~OtlpHttpClient ()
 
 OtlpHttpClient (const OtlpHttpClient &)=delete
 
OtlpHttpClient & operator= (const OtlpHttpClient &)=delete
 
 OtlpHttpClient (OtlpHttpClient &&)=delete
 
OtlpHttpClient & operator= (OtlpHttpClient &&)=delete
 
sdk::common::ExportResult Export (const google::protobuf::Message &message) noexcept
 Sync export. More...
 
sdk::common::ExportResult Export (const google::protobuf::Message &message, std::function< bool(opentelemetry::sdk::common::ExportResult)> &&result_callback) noexcept
 Async export. More...
 
sdk::common::ExportResult Export (const google::protobuf::Message &message, std::function< bool(opentelemetry::sdk::common::ExportResult)> &&result_callback, std::size_t max_running_requests) noexcept
 Async export. More...
 
bool ForceFlush (std::chrono::microseconds timeout=(std::chrono::microseconds::max)()) noexcept
 Force flush the HTTP client. More...
 
bool Shutdown (std::chrono::microseconds timeout=std::chrono::microseconds(0)) noexcept
 Shut down the HTTP client. More...
 
void ReleaseSession (const opentelemetry::ext::http::client::Session &session) noexcept
 Release the lifetime of specify session. More...
 
const OtlpHttpClientOptions & GetOptions () const noexcept
 Get options of current OTLP http client. More...
 
bool IsShutdown () const noexcept
 Get if this OTLP http client is shutdown. More...
 
 OtlpHttpClient (OtlpHttpClientOptions &&options)
 Create an OtlpHttpClient using the given options. More...
 
 ~OtlpHttpClient ()
 
 OtlpHttpClient (const OtlpHttpClient &)=delete
 
OtlpHttpClient & operator= (const OtlpHttpClient &)=delete
 
 OtlpHttpClient (OtlpHttpClient &&)=delete
 
OtlpHttpClient & operator= (OtlpHttpClient &&)=delete
 
sdk::common::ExportResult Export (const google::protobuf::Message &message) noexcept
 Sync export. More...
 
sdk::common::ExportResult Export (const google::protobuf::Message &message, std::function< bool(opentelemetry::sdk::common::ExportResult)> &&result_callback) noexcept
 Async export. More...
 
sdk::common::ExportResult Export (const google::protobuf::Message &message, std::function< bool(opentelemetry::sdk::common::ExportResult)> &&result_callback, std::size_t max_running_requests) noexcept
 Async export. More...
 
bool ForceFlush (std::chrono::microseconds timeout=(std::chrono::microseconds::max)()) noexcept
 Force flush the HTTP client. More...
 
bool Shutdown (std::chrono::microseconds timeout=std::chrono::microseconds(0)) noexcept
 Shut down the HTTP client. More...
 
void ReleaseSession (const opentelemetry::ext::http::client::Session &session) noexcept
 Release the lifetime of specify session. More...
 
const OtlpHttpClientOptions & GetOptions () const noexcept
 Get options of current OTLP http client. More...
 
bool IsShutdown () const noexcept
 Get if this OTLP http client is shutdown. More...
 

Friends

class OtlpHttpExporterTestPeer
 
class OtlpHttpLogRecordExporterTestPeer
 
class OtlpHttpMetricExporterTestPeer
 

Constructor & Destructor Documentation

◆ OtlpHttpClient() [1/6]

exporter::otlp::OtlpHttpClient::OtlpHttpClient ( OtlpHttpClientOptions &&  options)
explicit

Create an OtlpHttpClient using the given options.

◆ ~OtlpHttpClient() [1/2]

exporter::otlp::OtlpHttpClient::~OtlpHttpClient ( )

◆ OtlpHttpClient() [2/6]

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

◆ OtlpHttpClient() [3/6]

exporter::otlp::OtlpHttpClient::OtlpHttpClient ( OtlpHttpClient &&  )
delete

◆ OtlpHttpClient() [4/6]

exporter::otlp::OtlpHttpClient::OtlpHttpClient ( OtlpHttpClientOptions &&  options)
explicit

Create an OtlpHttpClient using the given options.

◆ ~OtlpHttpClient() [2/2]

exporter::otlp::OtlpHttpClient::~OtlpHttpClient ( )

◆ OtlpHttpClient() [5/6]

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

◆ OtlpHttpClient() [6/6]

exporter::otlp::OtlpHttpClient::OtlpHttpClient ( OtlpHttpClient &&  )
delete

Member Function Documentation

◆ Export() [1/6]

sdk::common::ExportResult exporter::otlp::OtlpHttpClient::Export ( const google::protobuf::Message &  message)
noexcept

Sync export.

Parameters
messagemessage to export, it should be ExportTraceServiceRequest, ExportMetricsServiceRequest or ExportLogsServiceRequest
Returns
return the status of this operation

◆ Export() [2/6]

sdk::common::ExportResult exporter::otlp::OtlpHttpClient::Export ( const google::protobuf::Message &  message)
noexcept

Sync export.

Parameters
messagemessage to export, it should be ExportTraceServiceRequest, ExportMetricsServiceRequest or ExportLogsServiceRequest
Returns
return the status of this operation

◆ Export() [3/6]

sdk::common::ExportResult exporter::otlp::OtlpHttpClient::Export ( const google::protobuf::Message &  message,
std::function< bool(opentelemetry::sdk::common::ExportResult)> &&  result_callback 
)
noexcept

Async export.

Parameters
messagemessage to export, it should be ExportTraceServiceRequest, ExportMetricsServiceRequest or ExportLogsServiceRequest
result_callbackcallback to call when the exporting is done
Returns
return the status of this operation

◆ Export() [4/6]

sdk::common::ExportResult exporter::otlp::OtlpHttpClient::Export ( const google::protobuf::Message &  message,
std::function< bool(opentelemetry::sdk::common::ExportResult)> &&  result_callback 
)
noexcept

Async export.

Parameters
messagemessage to export, it should be ExportTraceServiceRequest, ExportMetricsServiceRequest or ExportLogsServiceRequest
result_callbackcallback to call when the exporting is done
Returns
return the status of this operation

◆ Export() [5/6]

sdk::common::ExportResult exporter::otlp::OtlpHttpClient::Export ( const google::protobuf::Message &  message,
std::function< bool(opentelemetry::sdk::common::ExportResult)> &&  result_callback,
std::size_t  max_running_requests 
)
noexcept

Async export.

Parameters
messagemessage to export, it should be ExportTraceServiceRequest, ExportMetricsServiceRequest or ExportLogsServiceRequest
result_callbackcallback to call when the exporting is done
max_running_requestswait for at most max_running_requests running requests
Returns
return the status of this operation

◆ Export() [6/6]

sdk::common::ExportResult exporter::otlp::OtlpHttpClient::Export ( const google::protobuf::Message &  message,
std::function< bool(opentelemetry::sdk::common::ExportResult)> &&  result_callback,
std::size_t  max_running_requests 
)
noexcept

Async export.

Parameters
messagemessage to export, it should be ExportTraceServiceRequest, ExportMetricsServiceRequest or ExportLogsServiceRequest
result_callbackcallback to call when the exporting is done
max_running_requestswait for at most max_running_requests running requests
Returns
return the status of this operation

◆ ForceFlush() [1/2]

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

Force flush the HTTP client.

◆ ForceFlush() [2/2]

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

Force flush the HTTP client.

◆ GetOptions() [1/2]

const OtlpHttpClientOptions& exporter::otlp::OtlpHttpClient::GetOptions ( ) const
inlinenoexcept

Get options of current OTLP http client.

Returns
options of current OTLP http client.

Definition at line 223 of file includes/opentelemetry/exporters/otlp/otlp_http_client.h.

◆ GetOptions() [2/2]

const OtlpHttpClientOptions& exporter::otlp::OtlpHttpClient::GetOptions ( ) const
inlinenoexcept

Get options of current OTLP http client.

Returns
options of current OTLP http client.

Definition at line 223 of file 9.2/includes/opentelemetry/exporters/otlp/otlp_http_client.h.

◆ IsShutdown() [1/2]

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

Get if this OTLP http client is shutdown.

Returns
return true after Shutdown is called.

◆ IsShutdown() [2/2]

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

Get if this OTLP http client is shutdown.

Returns
return true after Shutdown is called.

◆ operator=() [1/4]

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

◆ operator=() [2/4]

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

◆ operator=() [3/4]

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

◆ operator=() [4/4]

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

◆ ReleaseSession() [1/2]

void exporter::otlp::OtlpHttpClient::ReleaseSession ( const opentelemetry::ext::http::client::Session &  session)
noexcept

Release the lifetime of specify session.

Parameters
sessionthe session to release

◆ ReleaseSession() [2/2]

void exporter::otlp::OtlpHttpClient::ReleaseSession ( const opentelemetry::ext::http::client::Session &  session)
noexcept

Release the lifetime of specify session.

Parameters
sessionthe session to release

◆ Shutdown() [1/2]

bool exporter::otlp::OtlpHttpClient::Shutdown ( std::chrono::microseconds  timeout = std::chrono::microseconds(0))
noexcept

Shut down the HTTP 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::OtlpHttpClient::Shutdown ( std::chrono::microseconds  timeout = std::chrono::microseconds(0))
noexcept

Shut down the HTTP client.

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

Friends And Related Function Documentation

◆ OtlpHttpExporterTestPeer

OtlpHttpExporterTestPeer
friend

◆ OtlpHttpLogRecordExporterTestPeer

OtlpHttpLogRecordExporterTestPeer
friend

◆ OtlpHttpMetricExporterTestPeer

OtlpHttpMetricExporterTestPeer
friend

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