Enum json_job_dispatch::DirectorError
source · [−]#[non_exhaustive]
pub enum DirectorError {
Show 13 variants
NotADirectory {
path: PathBuf,
},
DuplicateHandler {
kind: String,
},
CreateDirectory {
outbox: Outbox,
source: Error,
},
CreateFile {
filename: PathBuf,
source: Error,
},
WriteFile {
filename: PathBuf,
source: Error,
},
MoveJob {
outbox: Outbox,
filepath: PathBuf,
source: Error,
},
ListQueue {
path: PathBuf,
source: Error,
},
WatchQueue {
path: PathBuf,
source: Error,
},
OpenJob {
filepath: PathBuf,
source: Error,
},
CreateDeferJob {
filepath: PathBuf,
source: Error,
},
WriteDeferJob {
filepath: PathBuf,
source: Error,
},
RuntimeError {
source: Error,
},
Handler {
source: JobError,
},
}
Expand description
Errors which may occur when running a director.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
NotADirectory
Fields
path: PathBuf
The path given to the director.
The director was given a non-directory as its input queue path.
DuplicateHandler
Fields
kind: String
The duplicate kind
.
Two handlers for the same kind
were added.
CreateDirectory
Failure to create outbox directory.
CreateFile
Failure to create a stamp or reason file.
WriteFile
Failure to write a stamp or reason file.
MoveJob
Fields
outbox: Outbox
The outbox that the job was to be moved into.
filepath: PathBuf
The job file that could not be moved.
source: Error
The source of the error.
Failure to move a job to an outbox.
ListQueue
Failure to list the input queue’s directory.
WatchQueue
Failure to watch a queue directory for new files.
OpenJob
Failure to open a job file.
CreateDeferJob
Failure to create a defer job.
WriteDeferJob
Failure to write a defer job.
RuntimeError
Fields
source: Error
The source of the error.
A handler returned an error.
Handler
Fields
source: JobError
The source of the error.
A handler returned an error.
Trait Implementations
sourceimpl Debug for DirectorError
impl Debug for DirectorError
sourceimpl Display for DirectorError
impl Display for DirectorError
sourceimpl Error for DirectorError
impl Error for DirectorError
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()
Auto Trait Implementations
impl !RefUnwindSafe for DirectorError
impl Send for DirectorError
impl Sync for DirectorError
impl Unpin for DirectorError
impl !UnwindSafe for DirectorError
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