|
Aria 2.0.0
C++23 MVVM framework (C++20 minimum) — reactive, coroutine-first, ABI-layered
|
One trace event. More...
#include <diagnostics.hpp>
Public Member Functions | |
| std::string_view | category_name () const noexcept |
Public Attributes | |
| TraceCategory | category |
| Coarse routing label. | |
| TracePayload | payload |
| Per-category payload. | |
| std::chrono::steady_clock::time_point | time |
| Monotonic timestamp at publish time. | |
| std::optional<::aria::Error > | error |
| Optional Error snapshot (for *_fail / *_error events). | |
One trace event.
Constructed inline at the publish site (typically on the stack); the sink takes a const& and is responsible for any further copy / serialise it does. Optional error lets failure events ride the same channel without forcing every event to carry a (mostly empty) Error payload.
|
inlinenodiscardnoexcept |
| TraceCategory aria::TraceEvent::category |
Coarse routing label.
| TracePayload aria::TraceEvent::payload |
Per-category payload.
| std::chrono::steady_clock::time_point aria::TraceEvent::time |
Monotonic timestamp at publish time.
Useful for event ordering; consumers that don't need it pay only one steady_clock::now() per publish (cheap on commodity CPUs).
| std::optional<::aria::Error> aria::TraceEvent::error |
Optional Error snapshot (for *_fail / *_error events).
nullopt for happy-path events; populated factories carry it so consumers can route failure traces without fishing into the payload variant.