register_signal_cleanup_scoped

Function register_signal_cleanup_scoped 

Source
pub fn register_signal_cleanup_scoped(
    callback: Pin<Box<dyn Future<Output = ()> + Send>>,
) -> SignalCleanupGuard
Expand description

Register a scoped cleanup callback to be executed on SIGINT/SIGTERM Returns a guard that automatically unregisters the callback when dropped