pub enum ActivityCloseTimeouts {
ScheduleToClose(Duration),
StartToClose(Duration),
Both {
schedule_to_close: Duration,
start_to_close: Duration,
},
}Expand description
Represents Activity schedule-to-close and start-to-close timeouts for the purposes of specifying Activity options. Specifying at least one of them is required, but specifying both is also allowed. Note that this type does not cover all available timeout options for an Activity.
Variants§
ScheduleToClose(Duration)
Total time the Activity is allowed to run, including retries.
StartToClose(Duration)
Maximum time of a single Activity execution attempt. Note that the Temporal Server doesn’t
detect Worker process failures directly. It relies on this timeout to detect that an
Activity that didn’t complete on time. So this timeout should be as short as the longest
possible execution of the Activity body. Potentially long running Activities must specify
heartbeat_timeout in options and heartbeat from the activity periodically for timely
failure detection.
Both
Applies both execution-attempt and overall-completion bounds.
Implementations§
Source§impl ActivityCloseTimeouts
impl ActivityCloseTimeouts
Sourcepub fn schedule_to_close(&self) -> Option<Duration>
pub fn schedule_to_close(&self) -> Option<Duration>
Returns value of Self::ScheduleToClose or Self::Both::schedule_to_close.
Sourcepub fn start_to_close(&self) -> Option<Duration>
pub fn start_to_close(&self) -> Option<Duration>
Returns value of Self::StartToClose or Self::Both::start_to_close.
Trait Implementations§
Source§impl Clone for ActivityCloseTimeouts
impl Clone for ActivityCloseTimeouts
Source§fn clone(&self) -> ActivityCloseTimeouts
fn clone(&self) -> ActivityCloseTimeouts
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for ActivityCloseTimeouts
Source§impl Debug for ActivityCloseTimeouts
impl Debug for ActivityCloseTimeouts
impl Eq for ActivityCloseTimeouts
Source§impl PartialEq for ActivityCloseTimeouts
impl PartialEq for ActivityCloseTimeouts
impl StructuralPartialEq for ActivityCloseTimeouts
Auto Trait Implementations§
impl Freeze for ActivityCloseTimeouts
impl RefUnwindSafe for ActivityCloseTimeouts
impl Send for ActivityCloseTimeouts
impl Sync for ActivityCloseTimeouts
impl Unpin for ActivityCloseTimeouts
impl UnsafeUnpin for ActivityCloseTimeouts
impl UnwindSafe for ActivityCloseTimeouts
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request