14#include <absl/status/status.h>
115 alignas(kStorageAlign)
unsigned char storage_[kStorageSize];
116 bool engaged_ =
false;
Move-only RAII handle to one action, session, or transport span.
Definition span.h:37
std::string SpanIdHex() const
Return the 16-character span id, or empty when inactive.
Definition tracer.cc:320
std::string TraceIdHex() const
Return the 32-character trace id, or empty when inactive.
Definition tracer.cc:312
bool IsRecording() const noexcept
Whether this handle currently records attributes and events.
Definition tracer.cc:205
void UpdateName(std::string_view name)
Replace the name that will be exported when the span ends.
Definition tracer.cc:298
void SetStatus(const absl::Status &status)
Map an A11 operation status onto the span's OTel outcome.
Definition tracer.cc:269
absl::Status InjectContext(data::ByteMap &headers) const
Inject trace context and inherited baggage into reserved A11 headers.
Definition tracer.cc:328
void End() noexcept
Finish the span and release its implementation; safe to call repeatedly.
Definition tracer.cc:305
void SetAttribute(std::string_view key, std::string_view value)
Set or replace a string attribute on the live span.
Definition tracer.cc:209
void AddEvent(std::string_view name)
Record a named point-in-time event.
Definition tracer.cc:244
Factory that makes parentage explicit for A11's migrating fibers.
Definition tracer.h:21
Definition provider.cc:47
SpanStatus
OpenTelemetry outcome states, mirrored to keep OTel out of this API.
Definition span.h:24
SpanKind
OpenTelemetry span relationships, mirrored to keep OTel out of this API.
Definition span.h:21
Future< T > SubmitWithCancellationHook(absl::AnyInvocable< absl::StatusOr< T >() && > work, std::function< void()> cancellation_hook, thread::TreeOptions tree_options)
Run work on A11's fiber pool with application-specific cancellation.
Definition executor.h:30
A11's core wire value types: chunks, node fragments and messages.