pub enum AppStatus {
Running,
Paused(PausedAppReason),
Disabled(DisabledAppReason),
}
Expand description
The status of an installed app.
Variants§
Running
The app is enabled and running normally.
Paused(PausedAppReason)
Enabled, but stopped due to some recoverable problem.
The app “hopes” to be Running again as soon as possible.
Holochain may restart the app automatically if it can. It may also be
restarted manually via the StartApp
admin method.
Paused apps will be automatically set to Running when the conductor restarts.
Disabled(DisabledAppReason)
Disabled and stopped, either manually by the user, or automatically due to an unrecoverable error. App must be Enabled before running again, and will not restart automaticaly on conductor reboot.
Implementations§
source§impl AppStatus
impl AppStatus
sourcepub fn is_enabled(&self) -> bool
pub fn is_enabled(&self) -> bool
Does this status correspond to an Enabled state? If false, this indicates a Disabled state.
sourcepub fn is_running(&self) -> bool
pub fn is_running(&self) -> bool
Does this status correspond to a Running state? If false, this indicates a Stopped state.
sourcepub fn transition(&mut self, transition: AppStatusTransition) -> AppStatusFx
pub fn transition(&mut self, transition: AppStatusTransition) -> AppStatusFx
Transition a status from one state to another. If None, the transition was not valid, and the status did not change.
Trait Implementations§
source§impl<'de> Deserialize<'de> for AppStatus
impl<'de> Deserialize<'de> for AppStatus
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<AppStatus, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<AppStatus, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
source§impl From<AppInfoStatus> for AppStatus
impl From<AppInfoStatus> for AppStatus
source§fn from(i: AppInfoStatus) -> AppStatus
fn from(i: AppInfoStatus) -> AppStatus
source§impl From<AppStatus> for AppInfoStatus
impl From<AppStatus> for AppInfoStatus
source§fn from(i: AppStatus) -> AppInfoStatus
fn from(i: AppStatus) -> AppInfoStatus
source§impl From<AppStatus> for AppStatusKind
impl From<AppStatus> for AppStatusKind
source§fn from(status: AppStatus) -> AppStatusKind
fn from(status: AppStatus) -> AppStatusKind
source§impl From<StoppedAppReason> for AppStatus
impl From<StoppedAppReason> for AppStatus
source§fn from(reason: StoppedAppReason) -> AppStatus
fn from(reason: StoppedAppReason) -> AppStatus
source§impl PartialEq<AppStatus> for AppStatus
impl PartialEq<AppStatus> for AppStatus
source§impl Serialize for AppStatus
impl Serialize for AppStatus
source§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
source§impl TryFrom<&AppStatus> for SerializedBytes
impl TryFrom<&AppStatus> for SerializedBytes
§type Error = SerializedBytesError
type Error = SerializedBytesError
source§fn try_from(t: &AppStatus) -> Result<SerializedBytes, SerializedBytesError>
fn try_from(t: &AppStatus) -> Result<SerializedBytes, SerializedBytesError>
source§impl TryFrom<AppStatus> for SerializedBytes
impl TryFrom<AppStatus> for SerializedBytes
§type Error = SerializedBytesError
type Error = SerializedBytesError
source§fn try_from(t: AppStatus) -> Result<SerializedBytes, SerializedBytesError>
fn try_from(t: AppStatus) -> Result<SerializedBytes, SerializedBytesError>
source§impl TryFrom<SerializedBytes> for AppStatus
impl TryFrom<SerializedBytes> for AppStatus
§type Error = SerializedBytesError
type Error = SerializedBytesError
source§fn try_from(sb: SerializedBytes) -> Result<AppStatus, SerializedBytesError>
fn try_from(sb: SerializedBytes) -> Result<AppStatus, SerializedBytesError>
impl Eq for AppStatus
impl StructuralEq for AppStatus
impl StructuralPartialEq for AppStatus
Auto Trait Implementations§
impl RefUnwindSafe for AppStatus
impl Send for AppStatus
impl Sync for AppStatus
impl Unpin for AppStatus
impl UnwindSafe for AppStatus
Blanket Implementations§
§impl<T> Any for Twhere
T: Any + ?Sized,
impl<T> Any for Twhere
T: Any + ?Sized,
§fn type_id_compat(&self) -> TypeId
fn type_id_compat(&self) -> TypeId
§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
§impl<F, W, T, D> Deserialize<With<T, W>, D> for Fwhere
W: DeserializeWith<F, T, D>,
D: Fallible + ?Sized,
F: ?Sized,
impl<F, W, T, D> Deserialize<With<T, W>, D> for Fwhere
W: DeserializeWith<F, T, D>,
D: Fallible + ?Sized,
F: ?Sized,
§fn deserialize(
&self,
deserializer: &mut D
) -> Result<With<T, W>, <D as Fallible>::Error>
fn deserialize(
&self,
deserializer: &mut D
) -> Result<With<T, W>, <D as Fallible>::Error>
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
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> 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> ⓘ
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self
from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self
is actually part of its subset T
(and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset
but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self
to the equivalent element of its superset.