pub enum RunState {
Claimed,
Running,
Aftercare,
Aborted,
Merged,
Failed,
NeedsReview,
Cancelled,
RateLimited,
Orphaned,
}Expand description
Every value the runs.state column can hold. The ladder runs
claimed → running → aftercare and then to one terminal state, either an
outcome written by Store::finish_run or aborted from a rolled-back
claim. Values are the exact strings already stored; there is no migration.
Variants§
Claimed
Running
Aftercare
Aborted
A claim rolled back before a process existed.
Merged
Failed
NeedsReview
Cancelled
RateLimited
Orphaned
Implementations§
Source§impl RunState
impl RunState
pub fn as_str(self) -> &'static str
Sourcepub fn parse(value: &str) -> Result<Self, StoreError>
pub fn parse(value: &str) -> Result<Self, StoreError>
Reads a state written by an older or newer binary. An unrecognized value is an error rather than a fallback: silently treating it as nonterminal would let the daemon act on a run it cannot classify.
Sourcepub fn is_terminal(self) -> bool
pub fn is_terminal(self) -> bool
Whether the run has stopped: no lease, no supervision, no renewal.
Trait Implementations§
impl Copy for RunState
impl Eq for RunState
Source§impl FromSql for RunState
Reads runs.state as a typed value. An unrecognized string fails the row
rather than defaulting, so a state this binary does not understand can
never be mistaken for a live or a settled run.
impl FromSql for RunState
Reads runs.state as a typed value. An unrecognized string fails the row
rather than defaulting, so a state this binary does not understand can
never be mistaken for a live or a settled run.
Source§fn column_result(value: ValueRef<'_>) -> FromSqlResult<Self>
fn column_result(value: ValueRef<'_>) -> FromSqlResult<Self>
impl StructuralPartialEq for RunState
Auto Trait Implementations§
impl Freeze for RunState
impl RefUnwindSafe for RunState
impl Send for RunState
impl Sync for RunState
impl Unpin for RunState
impl UnsafeUnpin for RunState
impl UnwindSafe for RunState
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,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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.