Enum quickwit_actors::ActorExitStatus
source · [−]pub enum ActorExitStatus {
Success,
Quit,
DownstreamClosed,
Killed,
Failure(Arc<Error>),
Panicked,
}
Expand description
The actor exit status represents the outcome of the execution of an actor, after the end of the execution.
It is in many ways, similar to the exit status code of a program.
Variants
Success
The actor successfully exited.
It happens either because:
- all of the existing mailboxes were dropped and the actor message queue was exhausted. No new message could ever arrive to the actor. (This exit is triggered by the framework.) or
- the actor
process_message
method returnedErr(ExitStatusCode::Success)
. (This exit is triggered by the actor implementer.)
(This is equivalent to exit status code 0.) Note that this is not really an error.
Quit
The actor was asked to gracefully shutdown.
(Semantically equivalent to exit status code 130, triggered by SIGINT aka Ctrl-C, or SIGQUIT)
DownstreamClosed
The actor tried to send a message to a dowstream actor and failed. The logic ruled that the actor should be killed.
(Semantically equivalent to exit status code 141, triggered by SIGPIPE)
Killed
The actor was killed.
It can happen because:
- it received
Command::Kill
. - its kill switch was activated.
(Semantically equivalent to exit status code 137, triggered by SIGKILL)
Failure(Arc<Error>)
An unexpected error happened while processing a message.
Panicked
The thread or the task executing the actor loop panicked.
Implementations
sourceimpl ActorExitStatus
impl ActorExitStatus
pub fn is_success(&self) -> bool
Trait Implementations
sourceimpl Clone for ActorExitStatus
impl Clone for ActorExitStatus
sourcefn clone(&self) -> ActorExitStatus
fn clone(&self) -> ActorExitStatus
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for ActorExitStatus
impl Debug for ActorExitStatus
sourceimpl Display for ActorExitStatus
impl Display for ActorExitStatus
sourceimpl Error for ActorExitStatus
impl Error for ActorExitStatus
1.30.0 · sourcefn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
sourcefn backtrace(&self) -> Option<&Backtrace>
fn backtrace(&self) -> Option<&Backtrace>
backtrace
)Returns a stack backtrace, if available, of where this error occurred. Read more
1.0.0 · sourcefn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
sourceimpl From<Error> for ActorExitStatus
impl From<Error> for ActorExitStatus
Auto Trait Implementations
impl !RefUnwindSafe for ActorExitStatus
impl Send for ActorExitStatus
impl Sync for ActorExitStatus
impl Unpin for ActorExitStatus
impl !UnwindSafe for ActorExitStatus
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more