pub struct TelemetryRuntimeGuard { /* private fields */ }Implementations§
Source§impl TelemetryRuntimeGuard
impl TelemetryRuntimeGuard
pub fn noop() -> Self
Sourcepub fn handle(&self) -> TelemetryHandle
pub fn handle(&self) -> TelemetryHandle
Returns the cloneable business telemetry capability owned by this runtime.
pub fn logging_guard(&self) -> &LoggingGuard
pub fn log_filter_handle(&self) -> Option<LogFilterHandle>
pub fn subscriber_install_status(&self) -> SubscriberInstallStatus
pub fn status_handle(&self) -> ObservabilityStatusHandle
pub fn dropped_log_lines(&self) -> usize
pub fn shutdown(self) -> TelemetryShutdownReport
Sourcepub fn shutdown_with_timeout(self, timeout: Duration) -> TelemetryShutdownReport
pub fn shutdown_with_timeout(self, timeout: Duration) -> TelemetryShutdownReport
Flushes logging and telemetry providers without exceeding one shared timeout budget.
Sourcepub async fn shutdown_with_service_context(
self,
service_context: &ChildServiceContext,
timeout: Duration,
) -> TelemetryShutdownReport
pub async fn shutdown_with_service_context( self, service_context: &ChildServiceContext, timeout: Duration, ) -> TelemetryShutdownReport
Gracefully joins runtime-backed exporters and runs blocking provider flushes on the service’s owned blocking executor within one shared timeout budget.
Sourcepub async fn shutdown_with_drain_lease(
self,
lease: BlockingDrainLease,
timeout: Duration,
) -> TelemetryShutdownReport
pub async fn shutdown_with_drain_lease( self, lease: BlockingDrainLease, timeout: Duration, ) -> TelemetryShutdownReport
Runs the same flush as Self::shutdown_with_service_context on a drain lease
reserved from the owning scope while that scope was still open.
Owner finalization reaches telemetry after the owning task group has already been shut down, and the closed scope then refuses ordinary submissions. The lease carries the reserved allowance past that point without reopening the scope.
Trait Implementations§
Source§impl Debug for TelemetryRuntimeGuard
impl Debug for TelemetryRuntimeGuard
Source§impl Drop for TelemetryRuntimeGuard
impl Drop for TelemetryRuntimeGuard
Auto Trait Implementations§
impl !RefUnwindSafe for TelemetryRuntimeGuard
impl !UnwindSafe for TelemetryRuntimeGuard
impl Freeze for TelemetryRuntimeGuard
impl Send for TelemetryRuntimeGuard
impl Sync for TelemetryRuntimeGuard
impl Unpin for TelemetryRuntimeGuard
impl UnsafeUnpin for TelemetryRuntimeGuard
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