pub enum SessionState {
Accepting,
Closing,
Draining,
Closed,
}Expand description
Lifecycle of one active platform session generation.
Variants§
Accepting
New requests may be accepted.
Closing
New requests are rejected while accepted work is being classified for drain or cancel.
Draining
Accepted work is being drained, cancelled, or explicitly failed.
Closed
The generation no longer accepts completions that mutate active session state.
Implementations§
Source§impl SessionState
impl SessionState
Sourcepub const fn can_transition_to(self, next: Self) -> bool
pub const fn can_transition_to(self, next: Self) -> bool
Returns whether moving from this state to next is a valid idempotent lifecycle step.
Trait Implementations§
Source§impl Clone for SessionState
impl Clone for SessionState
Source§fn clone(&self) -> SessionState
fn clone(&self) -> SessionState
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 moreSource§impl Debug for SessionState
impl Debug for SessionState
Source§impl Hash for SessionState
impl Hash for SessionState
Source§impl PartialEq for SessionState
impl PartialEq for SessionState
impl Copy for SessionState
impl Eq for SessionState
impl StructuralPartialEq for SessionState
Auto Trait Implementations§
impl Freeze for SessionState
impl RefUnwindSafe for SessionState
impl Send for SessionState
impl Sync for SessionState
impl Unpin for SessionState
impl UnwindSafe for SessionState
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