pub struct SpanEvent<'a> {
pub name: &'a str,
pub attributes: Vec<(String, AttrValue)>,
pub time_unix_nanos: Option<u64>,
}Expand description
A point-in-time event recorded inside a span. Events do not have durations; they are the OTel equivalent of a structured log line scoped to a span.
Fields§
§name: &'a strEvent name (e.g. "exception", "cache.miss").
attributes: Vec<(String, AttrValue)>Event attributes. Semantic-convention keys apply here too; for
example, exception.message / exception.type on an "exception"
event.
time_unix_nanos: Option<u64>Event time override, nanoseconds since the Unix epoch. None means
“use the tracer’s current clock”.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for SpanEvent<'a>
impl<'a> RefUnwindSafe for SpanEvent<'a>
impl<'a> Send for SpanEvent<'a>
impl<'a> Sync for SpanEvent<'a>
impl<'a> Unpin for SpanEvent<'a>
impl<'a> UnsafeUnpin for SpanEvent<'a>
impl<'a> UnwindSafe for SpanEvent<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more