pub enum SchedulerError {
InvalidCron(String),
Database(SqlxError),
Db(DbError),
TaskFailed(String),
DuplicateJob(String),
AlreadyRunning {
pid: u32,
},
Detach(String),
Io(String),
}Expand description
Errors that can occur inside the scheduler subsystem.
Variants§
InvalidCron(String)
The provided cron expression could not be parsed.
The inner string contains the original expression and the parser’s error message.
Database(SqlxError)
A low-level SQLx error occurred during a database operation.
Db(DbError)
A high-level zeph-db error occurred (e.g. during migrations or connection setup).
TaskFailed(String)
The crate::TaskHandler returned an error during task execution.
The inner string is the human-readable description from the handler.
DuplicateJob(String)
A job with the given name already exists in the store.
Returned by crate::JobStore::insert_job on a UNIQUE constraint violation.
AlreadyRunning
Another zeph serve instance is already running with the given PID.
Returned by [crate::PidFile::acquire] when the pid file is locked by another process.
Detach(String)
Failed to detach the daemon process (fork, exec, or I/O redirection error).
Io(String)
A generic I/O error from daemon lifecycle operations (pid file, log file).
Trait Implementations§
Source§impl Debug for SchedulerError
impl Debug for SchedulerError
Source§impl Display for SchedulerError
impl Display for SchedulerError
Source§impl Error for SchedulerError
impl Error for SchedulerError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<DbError> for SchedulerError
impl From<DbError> for SchedulerError
Auto Trait Implementations§
impl Freeze for SchedulerError
impl !RefUnwindSafe for SchedulerError
impl Send for SchedulerError
impl Sync for SchedulerError
impl Unpin for SchedulerError
impl UnsafeUnpin for SchedulerError
impl !UnwindSafe for SchedulerError
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> 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 moreSource§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.