pub enum TerminationSignal {
Terminate,
Interrupt,
}Expand description
Unix signal sent before the hard-kill fallback during awaited shutdown.
The default is Terminate. Interrupt
lets a CLI handle cancellation as Ctrl-C, including cleaning up tools it
started in separate process groups. Such cleanup depends on the CLI; the
wrapper’s fallback only reaches its own process group.
Ignored on non-Unix platforms and with
process_group(false). Dropping a running
future always kills immediately without sending this signal first.
Variants§
Terminate
Send SIGTERM, preserving the default shutdown behavior.
Interrupt
Send SIGINT so the CLI can run its interrupt handler.
Trait Implementations§
Source§impl Clone for TerminationSignal
impl Clone for TerminationSignal
impl Copy for TerminationSignal
Source§impl Debug for TerminationSignal
impl Debug for TerminationSignal
Source§impl Default for TerminationSignal
impl Default for TerminationSignal
impl Eq for TerminationSignal
Source§impl PartialEq for TerminationSignal
impl PartialEq for TerminationSignal
impl StructuralPartialEq for TerminationSignal
Auto Trait Implementations§
impl Forget for TerminationSignal
impl Freeze for TerminationSignal
impl Move for TerminationSignal
impl RefUnwindSafe for TerminationSignal
impl Send for TerminationSignal
impl Sync for TerminationSignal
impl Unpin for TerminationSignal
impl UnsafeUnpin for TerminationSignal
impl UnwindSafe for TerminationSignal
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