pub struct JobReport {
pub id: String,
pub state: JobState,
pub result: Option<String>,
pub error: Option<String>,
pub attempts: u32,
pub visits: u32,
}Expand description
One Job’s outcome, as a reader of the run needs it.
error is here because without it a failed run is unreadable: a job shows
as DeadLettered with an empty body and the reason — which the job had all
along in last_error — never leaves the graph. Measured on a real run, a
grep job died on an invalid regex and the report said only “DeadLettered”.
visits is here for the same reason, one level up: a loop that hit its cap
looks identical to one that failed once.
Fields§
§id: String§state: JobState§result: Option<String>What it produced, if it succeeded.
error: Option<String>Why it failed, if it did.
attempts: u32Attempts of the latest entry, and how many times it was entered.
visits: u32Trait Implementations§
Source§impl<'de> Deserialize<'de> for JobReport
impl<'de> Deserialize<'de> for JobReport
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Forget for JobReport
impl Freeze for JobReport
impl RefUnwindSafe for JobReport
impl Send for JobReport
impl Sync for JobReport
impl Unpin for JobReport
impl UnsafeUnpin for JobReport
impl UnwindSafe for JobReport
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
Mutably borrows from an owned value. Read more