pub struct ScrubbedEnvelope<'a> { /* private fields */ }Expand description
Read-only view of an envelope whose payload has already been run through the per-tier scrubber. Constructed by the worker; consumed by sinks.
Clone + Copy are derived because every field is a borrow
(&ObsEnvelope, &[u8], or a 'static trait-object pointer),
so copying the value is a pointer-wide memcpy. Fan-out sinks rely
on this to multiplex one worker envelope across multiple child
sinks without re-running the scrubber. See obs/tok design § 4.5.
Implementations§
Source§impl<'a> ScrubbedEnvelope<'a>
impl<'a> ScrubbedEnvelope<'a>
Sourcepub fn envelope(&self) -> &ObsEnvelope
pub fn envelope(&self) -> &ObsEnvelope
Borrow the underlying envelope (without payload mutation).
Sourcepub fn schema(&self) -> Option<&'static dyn EventSchemaErased>
pub fn schema(&self) -> Option<&'static dyn EventSchemaErased>
Resolved schema, when this envelope’s full_name/schema_hash
is registered. None for foreign-producer envelopes.
Trait Implementations§
Source§impl<'a> Clone for ScrubbedEnvelope<'a>
impl<'a> Clone for ScrubbedEnvelope<'a>
Source§fn clone(&self) -> ScrubbedEnvelope<'a>
fn clone(&self) -> ScrubbedEnvelope<'a>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ScrubbedEnvelope<'_>
impl Debug for ScrubbedEnvelope<'_>
impl<'a> Copy for ScrubbedEnvelope<'a>
Auto Trait Implementations§
impl<'a> Freeze for ScrubbedEnvelope<'a>
impl<'a> !RefUnwindSafe for ScrubbedEnvelope<'a>
impl<'a> Send for ScrubbedEnvelope<'a>
impl<'a> Sync for ScrubbedEnvelope<'a>
impl<'a> Unpin for ScrubbedEnvelope<'a>
impl<'a> UnsafeUnpin for ScrubbedEnvelope<'a>
impl<'a> !UnwindSafe for ScrubbedEnvelope<'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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request