pub struct LogActor {
pub user_id: UserId,
pub session_id: SessionId,
pub trace_id: TraceId,
}Expand description
Mandatory attribution for every log row: who did the work, in which
session, on which trace. Bundled so every LogEntry::new call carries
the full triple instead of relying on hidden defaults.
Fields§
§user_id: UserId§session_id: SessionId§trace_id: TraceIdImplementations§
Source§impl LogActor
impl LogActor
pub const fn new( user_id: UserId, session_id: SessionId, trace_id: TraceId, ) -> Self
Sourcepub fn platform(trace_id: TraceId) -> Result<Self, LogAttributionUnset>
pub fn platform(trace_id: TraceId) -> Result<Self, LogAttributionUnset>
Platform telemetry (gateway access logs, OTLP ingest) has no human originator, so it declares the resolved system-admin owner. Fails when the runtime has not yet installed the logging attribution; the caller must propagate the error rather than fabricating a sentinel.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LogActor
impl RefUnwindSafe for LogActor
impl Send for LogActor
impl Sync for LogActor
impl Unpin for LogActor
impl UnsafeUnpin for LogActor
impl UnwindSafe for LogActor
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more