pub struct LogShipperHandle { /* private fields */ }Expand description
Cheap cloneable handle. enqueue is non-blocking and never fails — it’s
safe to call from the request path. When the shipper isn’t configured
the handle is None and calls are zero-cost.
Implementations§
Source§impl LogShipperHandle
impl LogShipperHandle
Sourcepub fn disabled() -> Self
pub fn disabled() -> Self
Construct a no-op handle. Used when the shipper isn’t configured —
the request middleware can still call enqueue without checking.
Sourcepub fn enqueue(&self, event: RequestLogEvent)
pub fn enqueue(&self, event: RequestLogEvent)
Non-blocking enqueue. Drops the event silently when the buffer is full, which is the right tradeoff for a request-path component: observability never blocks user traffic.
Trait Implementations§
Source§impl Clone for LogShipperHandle
impl Clone for LogShipperHandle
Source§fn clone(&self) -> LogShipperHandle
fn clone(&self) -> LogShipperHandle
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for LogShipperHandle
impl RefUnwindSafe for LogShipperHandle
impl Send for LogShipperHandle
impl Sync for LogShipperHandle
impl Unpin for LogShipperHandle
impl UnsafeUnpin for LogShipperHandle
impl UnwindSafe for LogShipperHandle
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