pub struct TaskConfig {
pub id: String,
pub priority: TaskPriority,
pub timeout: Option<Duration>,
pub dependencies: Vec<String>,
pub retry_policy: RetryPolicy,
pub resource_requirements: ResourceRequirements,
}Expand description
Task configuration and metadata
Fields§
§id: String§priority: TaskPriority§timeout: Option<Duration>§dependencies: Vec<String>§retry_policy: RetryPolicy§resource_requirements: ResourceRequirementsImplementations§
Source§impl TaskConfig
impl TaskConfig
pub fn new(id: impl Into<String>) -> Self
pub fn with_priority(self, priority: TaskPriority) -> Self
pub fn with_timeout(self, timeout: Duration) -> Self
pub fn with_dependencies(self, dependencies: Vec<String>) -> Self
pub fn with_retry_policy(self, retry_policy: RetryPolicy) -> Self
pub fn with_resource_requirements( self, requirements: ResourceRequirements, ) -> Self
Trait Implementations§
Source§impl Clone for TaskConfig
impl Clone for TaskConfig
Source§fn clone(&self) -> TaskConfig
fn clone(&self) -> TaskConfig
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for TaskConfig
impl RefUnwindSafe for TaskConfig
impl Send for TaskConfig
impl Sync for TaskConfig
impl Unpin for TaskConfig
impl UnwindSafe for TaskConfig
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)