pub struct Job {
pub id: JobId,
pub topic: String,
pub payload: Vec<u8>,
pub attempt: u32,
pub enqueued_at: SystemTime,
pub delivered_at: Option<SystemTime>,
pub visibility_timeout: Option<Duration>,
}Expand description
A unit of queued work.
Fields§
§id: JobIdThe unique ID of this job.
topic: StringThe topic/queue name the job was delivered from.
payload: Vec<u8>The raw payload bytes.
attempt: u32How many times this job has been attempted (0 = first attempt).
enqueued_at: SystemTimeWhen the job was first enqueued.
delivered_at: Option<SystemTime>When the job was delivered to the worker (None if not yet delivered).
visibility_timeout: Option<Duration>Optional visibility timeout - after this the job becomes visible again.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Job
impl RefUnwindSafe for Job
impl Send for Job
impl Sync for Job
impl Unpin for Job
impl UnsafeUnpin for Job
impl UnwindSafe for Job
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