NVIDIA DeepStream SDK API Reference

9.2 Release
sdk::trace::Recordable Class Referenceabstract

Detailed Description

Maintains a representation of a span in a format that can be processed by a recorder.

This class is thread-compatible.

Definition at line 44 of file includes/opentelemetry/sdk/trace/recordable.h.

Inheritance diagram for sdk::trace::Recordable:

Public Member Functions

virtual ~Recordable ()=default
 
virtual void SetIdentity (const opentelemetry::trace::SpanContext &span_context, opentelemetry::trace::SpanId parent_span_id) noexcept=0
 Set the span context and parent span id. More...
 
virtual void SetAttribute (nostd::string_view key, const opentelemetry::common::AttributeValue &value) noexcept=0
 Set an attribute of a span. More...
 
virtual void AddEvent (nostd::string_view name, opentelemetry::common::SystemTimestamp timestamp, const opentelemetry::common::KeyValueIterable &attributes) noexcept=0
 Add an event to a span. More...
 
void AddEvent (nostd::string_view name)
 Add an event to a span with default timestamp and attributes. More...
 
void AddEvent (nostd::string_view name, opentelemetry::common::SystemTimestamp timestamp)
 Add an event to a span with default (empty) attributes. More...
 
void AddEvent (nostd::string_view name, const opentelemetry::common::KeyValueIterable &attributes) noexcept
 Add an event to a span. More...
 
virtual void AddLink (const opentelemetry::trace::SpanContext &span_context, const opentelemetry::common::KeyValueIterable &attributes) noexcept=0
 Add a link to a span. More...
 
void AddLink (opentelemetry::trace::SpanContext span_context)
 Add a link to a span with default (empty) attributes. More...
 
virtual void SetStatus (opentelemetry::trace::StatusCode code, nostd::string_view description) noexcept=0
 Set the status of the span. More...
 
virtual void SetName (nostd::string_view name) noexcept=0
 Set the name of the span. More...
 
virtual void SetTraceFlags (opentelemetry::trace::TraceFlags) noexcept
 Set the trace flags of the span. More...
 
virtual void SetSpanKind (opentelemetry::trace::SpanKind span_kind) noexcept=0
 Set the spankind of the span. More...
 
virtual void SetResource (const opentelemetry::sdk::resource::Resource &resource) noexcept=0
 Set Resource of the span. More...
 
virtual void SetStartTime (opentelemetry::common::SystemTimestamp start_time) noexcept=0
 Set the start time of the span. More...
 
virtual void SetDuration (std::chrono::nanoseconds duration) noexcept=0
 Set the duration of the span. More...
 
virtual operator SpanData * () const
 Get the SpanData object for this Recordable. More...
 
virtual void SetInstrumentationScope (const InstrumentationScope &instrumentation_scope) noexcept=0
 Set the instrumentation scope of the span. More...
 
void SetInstrumentationLibrary (const InstrumentationScope &instrumentation_scope) noexcept
 
virtual ~Recordable ()=default
 
virtual void SetIdentity (const opentelemetry::trace::SpanContext &span_context, opentelemetry::trace::SpanId parent_span_id) noexcept=0
 Set the span context and parent span id. More...
 
virtual void SetAttribute (nostd::string_view key, const opentelemetry::common::AttributeValue &value) noexcept=0
 Set an attribute of a span. More...
 
virtual void AddEvent (nostd::string_view name, opentelemetry::common::SystemTimestamp timestamp, const opentelemetry::common::KeyValueIterable &attributes) noexcept=0
 Add an event to a span. More...
 
void AddEvent (nostd::string_view name)
 Add an event to a span with default timestamp and attributes. More...
 
void AddEvent (nostd::string_view name, opentelemetry::common::SystemTimestamp timestamp)
 Add an event to a span with default (empty) attributes. More...
 
void AddEvent (nostd::string_view name, const opentelemetry::common::KeyValueIterable &attributes) noexcept
 Add an event to a span. More...
 
virtual void AddLink (const opentelemetry::trace::SpanContext &span_context, const opentelemetry::common::KeyValueIterable &attributes) noexcept=0
 Add a link to a span. More...
 
void AddLink (opentelemetry::trace::SpanContext span_context)
 Add a link to a span with default (empty) attributes. More...
 
virtual void SetStatus (opentelemetry::trace::StatusCode code, nostd::string_view description) noexcept=0
 Set the status of the span. More...
 
virtual void SetName (nostd::string_view name) noexcept=0
 Set the name of the span. More...
 
virtual void SetTraceFlags (opentelemetry::trace::TraceFlags) noexcept
 Set the trace flags of the span. More...
 
virtual void SetSpanKind (opentelemetry::trace::SpanKind span_kind) noexcept=0
 Set the spankind of the span. More...
 
virtual void SetResource (const opentelemetry::sdk::resource::Resource &resource) noexcept=0
 Set Resource of the span. More...
 
virtual void SetStartTime (opentelemetry::common::SystemTimestamp start_time) noexcept=0
 Set the start time of the span. More...
 
virtual void SetDuration (std::chrono::nanoseconds duration) noexcept=0
 Set the duration of the span. More...
 
virtual operator SpanData * () const
 Get the SpanData object for this Recordable. More...
 
virtual void SetInstrumentationScope (const InstrumentationScope &instrumentation_scope) noexcept=0
 Set the instrumentation scope of the span. More...
 
void SetInstrumentationLibrary (const InstrumentationScope &instrumentation_scope) noexcept
 

Constructor & Destructor Documentation

◆ ~Recordable() [1/2]

virtual sdk::trace::Recordable::~Recordable ( )
virtualdefault

◆ ~Recordable() [2/2]

virtual sdk::trace::Recordable::~Recordable ( )
virtualdefault

Member Function Documentation

◆ AddEvent() [1/8]

void sdk::trace::Recordable::AddEvent ( nostd::string_view  name)
inline

Add an event to a span with default timestamp and attributes.

Parameters
namethe name of the event

Definition at line 79 of file includes/opentelemetry/sdk/trace/recordable.h.

References sdk::GetEmptyAttributes().

◆ AddEvent() [2/8]

void sdk::trace::Recordable::AddEvent ( nostd::string_view  name)
inline

Add an event to a span with default timestamp and attributes.

Parameters
namethe name of the event

Definition at line 79 of file 9.2/includes/opentelemetry/sdk/trace/recordable.h.

References sdk::GetEmptyAttributes().

◆ AddEvent() [3/8]

void sdk::trace::Recordable::AddEvent ( nostd::string_view  name,
const opentelemetry::common::KeyValueIterable &  attributes 
)
inlinenoexcept

Add an event to a span.

Parameters
namethe name of the event
attributesthe attributes associated with the event

Definition at line 100 of file includes/opentelemetry/sdk/trace/recordable.h.

◆ AddEvent() [4/8]

void sdk::trace::Recordable::AddEvent ( nostd::string_view  name,
const opentelemetry::common::KeyValueIterable &  attributes 
)
inlinenoexcept

Add an event to a span.

Parameters
namethe name of the event
attributesthe attributes associated with the event

Definition at line 100 of file 9.2/includes/opentelemetry/sdk/trace/recordable.h.

◆ AddEvent() [5/8]

void sdk::trace::Recordable::AddEvent ( nostd::string_view  name,
opentelemetry::common::SystemTimestamp  timestamp 
)
inline

Add an event to a span with default (empty) attributes.

Parameters
namethe name of the event
timestampthe timestamp of the event

Definition at line 90 of file includes/opentelemetry/sdk/trace/recordable.h.

References sdk::GetEmptyAttributes().

◆ AddEvent() [6/8]

void sdk::trace::Recordable::AddEvent ( nostd::string_view  name,
opentelemetry::common::SystemTimestamp  timestamp 
)
inline

Add an event to a span with default (empty) attributes.

Parameters
namethe name of the event
timestampthe timestamp of the event

Definition at line 90 of file 9.2/includes/opentelemetry/sdk/trace/recordable.h.

References sdk::GetEmptyAttributes().

◆ AddEvent() [7/8]

virtual void sdk::trace::Recordable::AddEvent ( nostd::string_view  name,
opentelemetry::common::SystemTimestamp  timestamp,
const opentelemetry::common::KeyValueIterable &  attributes 
)
pure virtualnoexcept

Add an event to a span.

Parameters
namethe name of the event
timestampthe timestamp of the event
attributesthe attributes associated with the event

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ AddEvent() [8/8]

virtual void sdk::trace::Recordable::AddEvent ( nostd::string_view  name,
opentelemetry::common::SystemTimestamp  timestamp,
const opentelemetry::common::KeyValueIterable &  attributes 
)
pure virtualnoexcept

Add an event to a span.

Parameters
namethe name of the event
timestampthe timestamp of the event
attributesthe attributes associated with the event

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ AddLink() [1/4]

virtual void sdk::trace::Recordable::AddLink ( const opentelemetry::trace::SpanContext &  span_context,
const opentelemetry::common::KeyValueIterable &  attributes 
)
pure virtualnoexcept

Add a link to a span.

Parameters
span_contextthe span context of the linked span
attributesthe attributes associated with the link

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ AddLink() [2/4]

virtual void sdk::trace::Recordable::AddLink ( const opentelemetry::trace::SpanContext &  span_context,
const opentelemetry::common::KeyValueIterable &  attributes 
)
pure virtualnoexcept

Add a link to a span.

Parameters
span_contextthe span context of the linked span
attributesthe attributes associated with the link

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ AddLink() [3/4]

void sdk::trace::Recordable::AddLink ( opentelemetry::trace::SpanContext  span_context)
inline

Add a link to a span with default (empty) attributes.

Parameters
span_contextthe span context of the linked span

Definition at line 119 of file includes/opentelemetry/sdk/trace/recordable.h.

References sdk::GetEmptyAttributes().

◆ AddLink() [4/4]

void sdk::trace::Recordable::AddLink ( opentelemetry::trace::SpanContext  span_context)
inline

Add a link to a span with default (empty) attributes.

Parameters
span_contextthe span context of the linked span

Definition at line 119 of file 9.2/includes/opentelemetry/sdk/trace/recordable.h.

References sdk::GetEmptyAttributes().

◆ operator SpanData *() [1/2]

virtual sdk::trace::Recordable::operator SpanData * ( ) const
inlineexplicitvirtual

Get the SpanData object for this Recordable.

Returns
SpanData*

Definition at line 173 of file includes/opentelemetry/sdk/trace/recordable.h.

◆ operator SpanData *() [2/2]

virtual sdk::trace::Recordable::operator SpanData * ( ) const
inlineexplicitvirtual

Get the SpanData object for this Recordable.

Returns
SpanData*

Definition at line 173 of file 9.2/includes/opentelemetry/sdk/trace/recordable.h.

◆ SetAttribute() [1/2]

virtual void sdk::trace::Recordable::SetAttribute ( nostd::string_view  key,
const opentelemetry::common::AttributeValue &  value 
)
pure virtualnoexcept

Set an attribute of a span.

Parameters
keythe name of the attribute
valuethe attribute value

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetAttribute() [2/2]

virtual void sdk::trace::Recordable::SetAttribute ( nostd::string_view  key,
const opentelemetry::common::AttributeValue &  value 
)
pure virtualnoexcept

Set an attribute of a span.

Parameters
keythe name of the attribute
valuethe attribute value

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetDuration() [1/2]

virtual void sdk::trace::Recordable::SetDuration ( std::chrono::nanoseconds  duration)
pure virtualnoexcept

Set the duration of the span.

Parameters
durationthe duration to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetDuration() [2/2]

virtual void sdk::trace::Recordable::SetDuration ( std::chrono::nanoseconds  duration)
pure virtualnoexcept

Set the duration of the span.

Parameters
durationthe duration to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetIdentity() [1/2]

virtual void sdk::trace::Recordable::SetIdentity ( const opentelemetry::trace::SpanContext &  span_context,
opentelemetry::trace::SpanId  parent_span_id 
)
pure virtualnoexcept

Set the span context and parent span id.

Parameters
span_contextthe span context to set
parent_span_idthe parent span id to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetIdentity() [2/2]

virtual void sdk::trace::Recordable::SetIdentity ( const opentelemetry::trace::SpanContext &  span_context,
opentelemetry::trace::SpanId  parent_span_id 
)
pure virtualnoexcept

Set the span context and parent span id.

Parameters
span_contextthe span context to set
parent_span_idthe parent span id to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetInstrumentationLibrary() [1/2]

void sdk::trace::Recordable::SetInstrumentationLibrary ( const InstrumentationScope &  instrumentation_scope)
inlinenoexcept

◆ SetInstrumentationLibrary() [2/2]

void sdk::trace::Recordable::SetInstrumentationLibrary ( const InstrumentationScope &  instrumentation_scope)
inlinenoexcept

◆ SetInstrumentationScope() [1/2]

virtual void sdk::trace::Recordable::SetInstrumentationScope ( const InstrumentationScope &  instrumentation_scope)
pure virtualnoexcept

Set the instrumentation scope of the span.

Parameters
instrumentation_scopethe instrumentation scope to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetInstrumentationScope() [2/2]

virtual void sdk::trace::Recordable::SetInstrumentationScope ( const InstrumentationScope &  instrumentation_scope)
pure virtualnoexcept

Set the instrumentation scope of the span.

Parameters
instrumentation_scopethe instrumentation scope to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetName() [1/2]

virtual void sdk::trace::Recordable::SetName ( nostd::string_view  name)
pure virtualnoexcept

Set the name of the span.

Parameters
namethe name to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetName() [2/2]

virtual void sdk::trace::Recordable::SetName ( nostd::string_view  name)
pure virtualnoexcept

Set the name of the span.

Parameters
namethe name to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetResource() [1/2]

virtual void sdk::trace::Recordable::SetResource ( const opentelemetry::sdk::resource::Resource &  resource)
pure virtualnoexcept

Set Resource of the span.

Parameters
resourcethe resource to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetResource() [2/2]

virtual void sdk::trace::Recordable::SetResource ( const opentelemetry::sdk::resource::Resource &  resource)
pure virtualnoexcept

Set Resource of the span.

Parameters
resourcethe resource to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetSpanKind() [1/2]

virtual void sdk::trace::Recordable::SetSpanKind ( opentelemetry::trace::SpanKind  span_kind)
pure virtualnoexcept

Set the spankind of the span.

Parameters
span_kindthe spankind to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetSpanKind() [2/2]

virtual void sdk::trace::Recordable::SetSpanKind ( opentelemetry::trace::SpanKind  span_kind)
pure virtualnoexcept

Set the spankind of the span.

Parameters
span_kindthe spankind to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetStartTime() [1/2]

virtual void sdk::trace::Recordable::SetStartTime ( opentelemetry::common::SystemTimestamp  start_time)
pure virtualnoexcept

Set the start time of the span.

Parameters
start_timethe start time to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetStartTime() [2/2]

virtual void sdk::trace::Recordable::SetStartTime ( opentelemetry::common::SystemTimestamp  start_time)
pure virtualnoexcept

Set the start time of the span.

Parameters
start_timethe start time to set

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetStatus() [1/2]

virtual void sdk::trace::Recordable::SetStatus ( opentelemetry::trace::StatusCode  code,
nostd::string_view  description 
)
pure virtualnoexcept

Set the status of the span.

Parameters
codethe status code
descriptiona description of the status

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetStatus() [2/2]

virtual void sdk::trace::Recordable::SetStatus ( opentelemetry::trace::StatusCode  code,
nostd::string_view  description 
)
pure virtualnoexcept

Set the status of the span.

Parameters
codethe status code
descriptiona description of the status

Implemented in sdk::trace::SpanData, sdk::trace::SpanData, sdk::trace::MultiRecordable, and sdk::trace::MultiRecordable.

◆ SetTraceFlags() [1/2]

virtual void sdk::trace::Recordable::SetTraceFlags ( opentelemetry::trace::TraceFlags  )
inlinevirtualnoexcept

◆ SetTraceFlags() [2/2]

virtual void sdk::trace::Recordable::SetTraceFlags ( opentelemetry::trace::TraceFlags  )
inlinevirtualnoexcept

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