pub fn try_record(
event: Event,
context: EventContext,
) -> Result<Option<EventId>, BenchWriteError>Expand description
Attempts to record a globally correlated event.
Ok(None) means that recording is disabled or uses the legacy sink, which
has no correlation identifiers.
§Errors
Returns a typed write error when an active session rejects non-finite data, has a full/disconnected queue, or has already finished.
§Examples
use ailloli_ui_bench::{try_record, Event, EventContext};
let id = try_record(
Event::Marker { ts_ms: 1, name: "ready".into() },
EventContext::default(),
)?;
let _ = id;