pub struct ReschedulePolicy {
pub delay: Option<TimeDelta>,
pub delay_function: Option<String>,
pub max_delay: Option<TimeDelta>,
pub unlimited: Option<bool>,
pub attempts: Option<i64>,
pub interval: Option<TimeDelta>,
}
Expand description
Reschedule configures how Tasks are rescheduled when they crash or fail.
This struct was generated based on the Go types of the official Nomad API client.
Fields§
§delay: Option<TimeDelta>
Delay is a minimum duration to wait between reschedule attempts. The delay function determines how much subsequent reschedule attempts are delayed by.
delay_function: Option<String>
DelayFunction determines how the delay progressively changes on subsequent reschedule attempts. Valid values are “exponential”, “constant”, and “fibonacci”.
max_delay: Option<TimeDelta>
MaxDelay is an upper bound on the delay.
unlimited: Option<bool>
Unlimited allows rescheduling attempts until they succeed
attempts: Option<i64>
Attempts limits the number of rescheduling attempts that can occur in an interval.
interval: Option<TimeDelta>
Interval is a duration in which we can limit the number of reschedule attempts.
Trait Implementations§
Source§impl Clone for ReschedulePolicy
impl Clone for ReschedulePolicy
Source§fn clone(&self) -> ReschedulePolicy
fn clone(&self) -> ReschedulePolicy
Returns a copy of the value. Read more
1.0.0 · 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 ReschedulePolicy
impl Debug for ReschedulePolicy
Source§impl Default for ReschedulePolicy
impl Default for ReschedulePolicy
Source§fn default() -> ReschedulePolicy
fn default() -> ReschedulePolicy
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ReschedulePolicy
impl<'de> Deserialize<'de> for ReschedulePolicy
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 ReschedulePolicy
impl PartialEq for ReschedulePolicy
Source§impl Serialize for ReschedulePolicy
impl Serialize for ReschedulePolicy
impl StructuralPartialEq for ReschedulePolicy
Auto Trait Implementations§
impl Freeze for ReschedulePolicy
impl RefUnwindSafe for ReschedulePolicy
impl Send for ReschedulePolicy
impl Sync for ReschedulePolicy
impl Unpin for ReschedulePolicy
impl UnwindSafe for ReschedulePolicy
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