pub struct DistributedRunEnvelope {Show 18 fields
pub schema_version: String,
pub job_id: String,
pub run_id: String,
pub task: AgentTask,
pub budget_limits: Option<RunBudgetLimits>,
pub recipe: RuntimeRecipe,
pub cycle_name: String,
pub cycle_index: u32,
pub idempotency_key: String,
pub deadline_unix_ms: Option<u64>,
pub lease_duration_ms: u64,
pub root_run_id: Option<String>,
pub trace_id: Option<String>,
pub run_definition_schema: Option<String>,
pub run_definition_digest: Option<String>,
pub claim_mode: Option<ClaimMode>,
pub resume_attempt: Option<u64>,
pub checkpoint_config: Option<DistributedCheckpointConfig>,
}Fields§
§schema_version: String§job_id: String§run_id: String§task: AgentTask§budget_limits: Option<RunBudgetLimits>§recipe: RuntimeRecipe§cycle_name: String§cycle_index: u32§idempotency_key: String§deadline_unix_ms: Option<u64>§lease_duration_ms: u64§root_run_id: Option<String>§trace_id: Option<String>§run_definition_schema: Option<String>§run_definition_digest: Option<String>§claim_mode: Option<ClaimMode>§resume_attempt: Option<u64>§checkpoint_config: Option<DistributedCheckpointConfig>Implementations§
Source§impl DistributedRunEnvelope
impl DistributedRunEnvelope
pub fn for_cycle( task: AgentTask, recipe: RuntimeRecipe, cycle_index: u32, cycle_name: impl Into<String>, run_id: Option<String>, deadline_unix_ms: Option<u64>, lease_duration_ms: u64, budget_limits: Option<RunBudgetLimits>, ) -> Result<Self, String>
pub fn enable_checkpoint_v2( self, root_run_id: impl Into<String>, trace_id: impl Into<String>, run_definition_digest: impl Into<String>, claim_mode: ClaimMode, resume_attempt: u64, checkpoint_config: DistributedCheckpointConfig, ) -> Result<Self, String>
pub fn for_checkpoint_cycle( task: AgentTask, recipe: RuntimeRecipe, cycle_index: u32, cycle_name: impl Into<String>, run_id: Option<String>, deadline_unix_ms: Option<u64>, lease_duration_ms: u64, budget_limits: Option<RunBudgetLimits>, root_run_id: impl Into<String>, trace_id: impl Into<String>, run_definition_digest: impl Into<String>, claim_mode: ClaimMode, resume_attempt: u64, checkpoint_config: DistributedCheckpointConfig, ) -> Result<Self, String>
pub fn is_checkpoint_v2(&self) -> bool
pub fn validate(&self) -> Result<(), String>
pub fn ensure_not_expired_at(&self, now_ms: u64) -> Result<(), String>
pub fn ensure_not_expired(&self) -> Result<(), String>
pub fn remaining_millis_at(&self, now_ms: u64) -> Option<u64>
pub fn to_dict(&self) -> Value
pub fn from_dict(payload: &Value) -> Result<Self, String>
Trait Implementations§
Source§impl Clone for DistributedRunEnvelope
impl Clone for DistributedRunEnvelope
Source§fn clone(&self) -> DistributedRunEnvelope
fn clone(&self) -> DistributedRunEnvelope
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DistributedRunEnvelope
impl Debug for DistributedRunEnvelope
Source§impl<'de> Deserialize<'de> for DistributedRunEnvelope
impl<'de> Deserialize<'de> for DistributedRunEnvelope
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 PartialEq for DistributedRunEnvelope
impl PartialEq for DistributedRunEnvelope
Source§impl Serialize for DistributedRunEnvelope
impl Serialize for DistributedRunEnvelope
impl StructuralPartialEq for DistributedRunEnvelope
Auto Trait Implementations§
impl Freeze for DistributedRunEnvelope
impl RefUnwindSafe for DistributedRunEnvelope
impl Send for DistributedRunEnvelope
impl Sync for DistributedRunEnvelope
impl Unpin for DistributedRunEnvelope
impl UnsafeUnpin for DistributedRunEnvelope
impl UnwindSafe for DistributedRunEnvelope
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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>
Converts
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>
Converts
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 moreCreates a shared type from an unshared type.