pub enum Stage {
Downloading,
Replaced,
Parking,
Restarting,
Done,
Failed,
}Expand description
How far a self-upgrade this deck set in motion has gotten.
POST /api/upgrade answers 202 and returns immediately - see its own
doc for why - so Progress is the only way a phone that asked for an
upgrade learns anything about it afterwards.
Variants§
Downloading
Downloading the release asset and replacing the binary. This bundles
what would otherwise be two stages: kaishin re-confirms the release
and downloads it inside one await with no hook to split, so from
here a phone cannot tell “still checking” from “still downloading” -
only that nothing has been swapped in yet. The confirmation that ran
before this stage started is already known to the phone: it is what
the to version in the 202 answered with.
Replaced
The new binary is in place and crate::web’s handover has been
signalled, but has not acted yet.
Parking
The handover is waiting for the run in flight, if any, to reach its
next node boundary. The deck answers throughout this - it is not the
unreachable gap, see web::hand_over.
Restarting
The listener has been released and the successor is starting. This is
the one genuinely unreachable moment, and it is meant to be
sub-second - see web::bind_waiting.
Done
A successor came up and confirmed it is running the release this upgrade asked for.
Failed
The upgrade did not reach Stage::Done. detail on Progress
says why.
Implementations§
Trait Implementations§
impl Copy for Stage
Source§impl<'de> Deserialize<'de> for Stage
impl<'de> Deserialize<'de> for Stage
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for Stage
impl StructuralPartialEq for Stage
Auto Trait Implementations§
impl Freeze for Stage
impl RefUnwindSafe for Stage
impl Send for Stage
impl Sync for Stage
impl Unpin for Stage
impl UnsafeUnpin for Stage
impl UnwindSafe for Stage
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more