|
A11 (C++ runtime)
Native C++ implementation of the A11 action and streaming runtime
|
Namespaces | |
| namespace | internal |
Classes | |
| struct | BaggageEntry |
| One decoded W3C baggage member propagated through nested and remote actions. More... | |
| struct | ProviderOptions |
| Configure how an A11 process records and exports agent traces. More... | |
| struct | RecordedEvent |
| Event captured on a span by the in-memory exporter. More... | |
| struct | RecordedSpan |
| Finished span snapshot returned by the in-memory exporter. More... | |
| class | Span |
| Move-only RAII handle to one action, session, or transport span. More... | |
| struct | TraceContext |
| SDK-independent W3C parent context recovered from reserved action headers. More... | |
| class | Tracer |
| Factory that makes parentage explicit for A11's migrating fibers. More... | |
Enumerations | |
| enum class | ExporterKind { kNone , kInMemory , kOstream , kOtlpHttp } |
| Destination used for spans produced by actions, sessions, and transports. More... | |
| enum class | SpanKind { kInternal , kServer , kClient , kProducer , kConsumer } |
| OpenTelemetry span relationships, mirrored to keep OTel out of this API. More... | |
| enum class | SpanStatus { kUnset , kOk , kError } |
| OpenTelemetry outcome states, mirrored to keep OTel out of this API. More... | |
Functions | |
| absl::Status | Configure (const ProviderOptions &options) |
| Install or replace the process-wide tracer provider. | |
| void | Shutdown () |
| Flush pending spans and restore the process to its unconfigured state. | |
| bool | IsConfigured () |
| Whether a tracer provider is currently installed. | |
| std::vector< RecordedSpan > | GetRecordedSpans () |
| Return in-memory spans oldest first; meaningful for kInMemory only. | |
| void | ClearRecordedSpans () |
| Clear spans retained by the in-memory exporter. | |
| absl::StatusOr< std::optional< TraceContext > > | ExtractTraceContext (const data::ByteMap &headers) |
| Extract a remote parent; nullopt means no tracing headers were supplied. | |
| absl::Status | InjectTraceContext (const TraceContext &context, data::ByteMap &headers) |
Serialize context into reserved headers, replacing existing values. | |
Variables | |
| constexpr std::string_view | kTraceparentHeader = "x-otel-traceparent" |
| Reserved action header carrying the W3C traceparent value. | |
| constexpr std::string_view | kTracestateHeader = "x-otel-tracestate" |
| Reserved action header carrying the W3C tracestate value. | |
| constexpr std::string_view | kBaggageHeader = "x-otel-baggage" |
| Reserved action header carrying request-scoped W3C baggage. | |
|
strong |
Destination used for spans produced by actions, sessions, and transports.
| Enumerator | |
|---|---|
| kNone | Unconfigured sentinel; Configure() rejects this value. |
| kInMemory | Retain finished spans for GetRecordedSpans(); useful in tests. |
| kOstream | Human-readable output for local debugging. |
| kOtlpHttp | Native OTLP/HTTP export; requires the A11_WITH_OTLP_HTTP build option. |
|
strong |
|
strong |
| void a11::obs::ClearRecordedSpans | ( | ) |
Clear spans retained by the in-memory exporter.
| absl::Status a11::obs::Configure | ( | const ProviderOptions & | options | ) |
Install or replace the process-wide tracer provider.
Tracing remains inactive until this returns OK.
| absl::StatusOr< std::optional< TraceContext > > a11::obs::ExtractTraceContext | ( | const data::ByteMap & | headers | ) |
Extract a remote parent; nullopt means no tracing headers were supplied.
Malformed or inconsistent reserved headers return an error so an action cannot silently detach from the caller's requested trace.
| std::vector< RecordedSpan > a11::obs::GetRecordedSpans | ( | ) |
Return in-memory spans oldest first; meaningful for kInMemory only.
| absl::Status a11::obs::InjectTraceContext | ( | const TraceContext & | context, |
| data::ByteMap & | headers | ||
| ) |
Serialize context into reserved headers, replacing existing values.
| bool a11::obs::IsConfigured | ( | ) |
Whether a tracer provider is currently installed.
| void a11::obs::Shutdown | ( | ) |
Flush pending spans and restore the process to its unconfigured state.
Reserved action header carrying request-scoped W3C baggage.
|
inlineconstexpr |
Reserved action header carrying the W3C traceparent value.
|
inlineconstexpr |
Reserved action header carrying the W3C tracestate value.