pub struct StageReporter { /* private fields */ }Expand description
A cloneable handle for writing this incarnation’s boot stages.
Cloning is cheap (a path, an Arc, and a flag) and every clone writes the
SAME record, so a stage reported from the store’s blocking thread is
immediately visible through the run loop’s guard.
Implementations§
Source§impl StageReporter
impl StageReporter
Sourcepub fn detached() -> Self
pub fn detached() -> Self
A reporter that writes nothing, for a caller with no claim to report
against: an embedder building ServerState
directly, or a test.
It is deliberately a real reporter rather than an Option: the boot
path reports at half a dozen seams, and threading an Option through
all of them would make “no reporter” a case each seam had to handle.
Its reports are logged (at debug) and dropped.
Sourcepub fn report(&self, stage: &str, detail: String)
pub fn report(&self, stage: &str, detail: String)
Report that this incarnation has reached stage, with one human
sentence of detail.
Infallible by design: a stage report is narration, and a boot must
never fail because it could not describe itself. A write that cannot
happen is reported through tracing at warn — the same channel the
stage line itself goes to, so the loss is never silent.
Trait Implementations§
Source§impl Clone for StageReporter
impl Clone for StageReporter
Source§fn clone(&self) -> StageReporter
fn clone(&self) -> StageReporter
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for StageReporter
impl RefUnwindSafe for StageReporter
impl Send for StageReporter
impl Sync for StageReporter
impl Unpin for StageReporter
impl UnsafeUnpin for StageReporter
impl UnwindSafe for StageReporter
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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> IntoMaybeUndefined<T> for T
impl<T> IntoMaybeUndefined<T> for T
Source§fn into_maybe_undefined(self) -> MaybeUndefined<T>
fn into_maybe_undefined(self) -> MaybeUndefined<T>
Source§impl<T> IntoOption<T> for T
impl<T> IntoOption<T> for T
Source§fn into_option(self) -> Option<T>
fn into_option(self) -> Option<T>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request