pub struct NewTask {
pub task_id: String,
pub step_id: String,
pub attempt: u32,
pub activity: String,
pub queue: String,
pub schema_ref: Option<String>,
pub input: Value,
pub idempotency_key: String,
pub retry: RetryPolicy,
pub lease_ttl_ms: u64,
pub timeout_ms: Option<u64>,
}Expand description
A task row to insert. It doubles as the outbox entry the host pushes to a worker.
Fields§
§task_id: String<run_id>:<step_id>.
step_id: StringThe step that owns the task.
attempt: u32Always 1 for a new task.
activity: StringActivity name the worker dispatches on.
queue: StringQueue the task is pushed to.
schema_ref: Option<String>Input schema reference, when the reducer named one.
input: ValueActivity input.
idempotency_key: String<run_id>:<step_id>:<attempt>; unique per dispatch attempt.
retry: RetryPolicyRetry policy resolved for this task.
lease_ttl_ms: u64Lease duration in milliseconds before the reaper may re-dispatch.
timeout_ms: Option<u64>Per-attempt wall-clock budget in milliseconds; None means no budget.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for NewTask
impl<'de> Deserialize<'de> for NewTask
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
Source§impl JsonSchema for NewTask
impl JsonSchema for NewTask
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreimpl StructuralPartialEq for NewTask
Auto Trait Implementations§
impl Freeze for NewTask
impl RefUnwindSafe for NewTask
impl Send for NewTask
impl Sync for NewTask
impl Unpin for NewTask
impl UnsafeUnpin for NewTask
impl UnwindSafe for NewTask
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