pub struct OperatorRequest { /* private fields */ }Expand description
One validated mutating operator request.
The request digest covers the action, target identity, expected version, and bounded arguments. Replaying an operation identifier with a different digest is a conflict rather than a repeat.
Implementations§
Source§impl OperatorRequest
impl OperatorRequest
Sourcepub fn launch(
operation_id: OperationId,
actor: ActorRef,
key: JobInstanceKey,
definition: DefinitionIdentity,
) -> OperatorRequest
pub fn launch( operation_id: OperationId, actor: ActorRef, key: JobInstanceKey, definition: DefinitionIdentity, ) -> OperatorRequest
Requests one launch of the instance selected by an identifying key.
Sourcepub fn restart(
operation_id: OperationId,
actor: ActorRef,
job_instance_id: JobInstanceId,
definition: DefinitionIdentity,
) -> OperatorRequest
pub fn restart( operation_id: OperationId, actor: ActorRef, job_instance_id: JobInstanceId, definition: DefinitionIdentity, ) -> OperatorRequest
Requests one restart attempt for an existing logical instance.
Sourcepub fn stop(
operation_id: OperationId,
actor: ActorRef,
job_execution_id: JobExecutionId,
expected_version: ExecutionVersion,
) -> OperatorRequest
pub fn stop( operation_id: OperationId, actor: ActorRef, job_execution_id: JobExecutionId, expected_version: ExecutionVersion, ) -> OperatorRequest
Requests one durable cooperative stop.
Sourcepub fn abandon(
operation_id: OperationId,
actor: ActorRef,
reason: ReasonCode,
job_execution_id: JobExecutionId,
expected_version: ExecutionVersion,
) -> OperatorRequest
pub fn abandon( operation_id: OperationId, actor: ActorRef, reason: ReasonCode, job_execution_id: JobExecutionId, expected_version: ExecutionVersion, ) -> OperatorRequest
Requests that one finished or recovered execution become ABANDONED.
Sourcepub fn recover(
operation_id: OperationId,
actor: ActorRef,
reason: ReasonCode,
directive: RecoveryDirective,
proposal: &RecoveryProposal,
) -> OperatorRequest
pub fn recover( operation_id: OperationId, actor: ActorRef, reason: ReasonCode, directive: RecoveryDirective, proposal: &RecoveryProposal, ) -> OperatorRequest
Requests one evidence-bound recovery decision.
Sourcepub const fn action(&self) -> OperatorAction
pub const fn action(&self) -> OperatorAction
Returns the requested action.
Returns the class a deployment authorizes before this call.
Sourcepub const fn operation_id(&self) -> &OperationId
pub const fn operation_id(&self) -> &OperationId
Borrows the caller-supplied idempotency key.
Sourcepub const fn reason(&self) -> Option<&ReasonCode>
pub const fn reason(&self) -> Option<&ReasonCode>
Borrows the closed-set reason code, when the action requires one.
Sourcepub const fn expected_version(&self) -> Option<ExecutionVersion>
pub const fn expected_version(&self) -> Option<ExecutionVersion>
Returns the observed optimistic version for a lifecycle mutation.
Sourcepub const fn digest(&self) -> &RequestDigest
pub const fn digest(&self) -> &RequestDigest
Returns the framework-computed canonical request digest.
Sourcepub const fn job_execution_id(&self) -> Option<JobExecutionId>
pub const fn job_execution_id(&self) -> Option<JobExecutionId>
Returns the targeted execution, when the action names one.
Sourcepub const fn job_instance_id(&self) -> Option<JobInstanceId>
pub const fn job_instance_id(&self) -> Option<JobInstanceId>
Returns the targeted logical instance, when the action names one.
Sourcepub fn job_instance_key(&self) -> Option<&JobInstanceKey>
pub fn job_instance_key(&self) -> Option<&JobInstanceKey>
Borrows the identifying key, when the action selects by key.
Only OperatorAction::Launch names one; every other action names an
instance or an execution.
Trait Implementations§
Source§impl Clone for OperatorRequest
impl Clone for OperatorRequest
Source§fn clone(&self) -> OperatorRequest
fn clone(&self) -> OperatorRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for OperatorRequest
impl Debug for OperatorRequest
impl Eq for OperatorRequest
Source§impl PartialEq for OperatorRequest
impl PartialEq for OperatorRequest
impl StructuralPartialEq for OperatorRequest
Auto Trait Implementations§
impl Freeze for OperatorRequest
impl RefUnwindSafe for OperatorRequest
impl Send for OperatorRequest
impl Sync for OperatorRequest
impl Unpin for OperatorRequest
impl UnsafeUnpin for OperatorRequest
impl UnwindSafe for OperatorRequest
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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> ⓘ
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> ⓘ
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 more