pub struct ActivityOptions {
pub name: String,
pub task_queue: String,
pub schedule_to_close_timeout: Option<Duration>,
pub schedule_to_start_timeout: Option<Duration>,
pub start_to_close_timeout: Option<Duration>,
pub heartbeat_timeout: Option<Duration>,
pub wait_for_cancellation: bool,
pub retry_policy: Option<RetryPolicy>,
}Expand description
ActivityOptions identifies an rpc method as a Temporal activity definition, and describes available activity configuration options
Fields§
§name: StringFully-qualified activity name
task_queue: StringOverride default task queue for activity
schedule_to_close_timeout: Option<Duration>Total time that a workflow is willing to wait for Activity to complete
schedule_to_start_timeout: Option<Duration>Time that the Activity Task can stay in the Task Queue before it is picked up by a Worker
start_to_close_timeout: Option<Duration>Maximum time of a single Activity execution attempt
heartbeat_timeout: Option<Duration>Heartbeat interval. Activity must call Activity.RecordHeartbeat(ctx, “my-heartbeat”)
wait_for_cancellation: boolWaitForCancellation - Whether to wait for canceled activity to be completed (activity can be failed, completed, cancel accepted)
retry_policy: Option<RetryPolicy>Specifies how to retry an Activity if an error occurs
Trait Implementations§
Source§impl Clone for ActivityOptions
impl Clone for ActivityOptions
Source§fn clone(&self) -> ActivityOptions
fn clone(&self) -> ActivityOptions
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 ActivityOptions
impl Debug for ActivityOptions
Source§impl Default for ActivityOptions
impl Default for ActivityOptions
Source§impl Message for ActivityOptions
impl Message for ActivityOptions
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message to a buffer. Read more
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message to a newly allocated buffer.
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message with a length-delimiter to a buffer. Read more
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message with a length-delimiter to a newly allocated buffer.
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes an instance of the message from a buffer. Read more
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes a length-delimited instance of the message from the buffer.
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes an instance of the message from a buffer, and merges it into
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self.Source§impl PartialEq for ActivityOptions
impl PartialEq for ActivityOptions
Source§fn eq(&self, other: &ActivityOptions) -> bool
fn eq(&self, other: &ActivityOptions) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for ActivityOptions
Auto Trait Implementations§
impl Freeze for ActivityOptions
impl RefUnwindSafe for ActivityOptions
impl Send for ActivityOptions
impl Sync for ActivityOptions
impl Unpin for ActivityOptions
impl UnsafeUnpin for ActivityOptions
impl UnwindSafe for ActivityOptions
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