Class MultiRecordable

Inheritance Relationships

Base Type

Class Documentation

class MultiRecordable : public opentelemetry::sdk::logs::Recordable

Public Functions

void AddRecordable(const LogRecordProcessor &processor, std::unique_ptr<Recordable> recordable) noexcept
const std::unique_ptr<Recordable> &GetRecordable(const LogRecordProcessor &processor) const noexcept
std::unique_ptr<Recordable> ReleaseRecordable(const LogRecordProcessor &processor) noexcept
void SetTimestamp(opentelemetry::common::SystemTimestamp timestamp) noexcept override

Set the timestamp for this log.

Parameters:

timestamp – the timestamp to set

void SetObservedTimestamp(opentelemetry::common::SystemTimestamp timestamp) noexcept override

Set the observed timestamp for this log.

Parameters:

timestamp – the timestamp to set

void SetSeverity(opentelemetry::logs::Severity severity) noexcept override

Set the severity for this log.

Parameters:

severity – the severity of the event

void SetBody(const opentelemetry::common::AttributeValue &message) noexcept override

Set body field for this log.

Parameters:

message – the body to set

void SetEventId(int64_t id, nostd::string_view name) noexcept override

Set the event id

Parameters:
  • id – the event id to set

  • name – the event name to set

void SetTraceId(const opentelemetry::trace::TraceId &trace_id) noexcept override

Set the trace id for this log.

Parameters:

trace_id – the trace id to set

void SetSpanId(const opentelemetry::trace::SpanId &span_id) noexcept override

Set the span id for this log.

Parameters:

span_id – the span id to set

void SetTraceFlags(const opentelemetry::trace::TraceFlags &trace_flags) noexcept override

Inject trace_flags for this log.

Parameters:

trace_flags – the trace flags to set

void SetAttribute(nostd::string_view key, const opentelemetry::common::AttributeValue &value) noexcept override

Set an attribute of a log.

Parameters:
  • key – the name of the attribute

  • value – the attribute value

void SetResource(const opentelemetry::sdk::resource::Resource &resource) noexcept override

Set Resource of this log

Parameters:

Resource – the resource to set

void SetInstrumentationScope(const opentelemetry::sdk::instrumentationscope::InstrumentationScope &instrumentation_scope) noexcept override

Set instrumentation_scope for this log.

Parameters:

instrumentation_scope – the instrumentation scope to set