#[non_exhaustive]pub struct StepExecution {Show 24 fields
pub step_name: Option<String>,
pub action: Option<String>,
pub timeout_seconds: Option<i64>,
pub on_failure: Option<String>,
pub max_attempts: Option<i32>,
pub execution_start_time: Option<DateTime>,
pub execution_end_time: Option<DateTime>,
pub step_status: Option<AutomationExecutionStatus>,
pub response_code: Option<String>,
pub inputs: Option<HashMap<String, String>>,
pub outputs: Option<HashMap<String, Vec<String>>>,
pub response: Option<String>,
pub failure_message: Option<String>,
pub failure_details: Option<FailureDetails>,
pub step_execution_id: Option<String>,
pub overridden_parameters: Option<HashMap<String, Vec<String>>>,
pub is_end: Option<bool>,
pub next_step: Option<String>,
pub is_critical: Option<bool>,
pub valid_next_steps: Option<Vec<String>>,
pub targets: Option<Vec<Target>>,
pub target_location: Option<TargetLocation>,
pub triggered_alarms: Option<Vec<AlarmStateInformation>>,
pub parent_step_details: Option<ParentStepDetails>,
}
Expand description
Detailed information about an the execution state of an Automation step.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.step_name: Option<String>
The name of this execution step.
action: Option<String>
The action this step performs. The action determines the behavior of the step.
timeout_seconds: Option<i64>
The timeout seconds of the step.
on_failure: Option<String>
The action to take if the step fails. The default value is Abort
.
max_attempts: Option<i32>
The maximum number of tries to run the action of the step. The default value is 1
.
execution_start_time: Option<DateTime>
If a step has begun execution, this contains the time the step started. If the step is in Pending status, this field isn't populated.
execution_end_time: Option<DateTime>
If a step has finished execution, this contains the time the execution ended. If the step hasn't yet concluded, this field isn't populated.
step_status: Option<AutomationExecutionStatus>
The execution status for this step.
response_code: Option<String>
The response code returned by the execution of the step.
inputs: Option<HashMap<String, String>>
Fully-resolved values passed into the step before execution.
outputs: Option<HashMap<String, Vec<String>>>
Returned values from the execution of the step.
response: Option<String>
A message associated with the response code for an execution.
failure_message: Option<String>
If a step failed, this message explains why the execution failed.
failure_details: Option<FailureDetails>
Information about the Automation failure.
step_execution_id: Option<String>
The unique ID of a step execution.
overridden_parameters: Option<HashMap<String, Vec<String>>>
A user-specified list of parameters to override when running a step.
is_end: Option<bool>
The flag which can be used to end automation no matter whether the step succeeds or fails.
next_step: Option<String>
The next step after the step succeeds.
is_critical: Option<bool>
The flag which can be used to help decide whether the failure of current step leads to the Automation failure.
valid_next_steps: Option<Vec<String>>
Strategies used when step fails, we support Continue and Abort. Abort will fail the automation when the step fails. Continue will ignore the failure of current step and allow automation to run the next step. With conditional branching, we add step:stepName to support the automation to go to another specific step.
targets: Option<Vec<Target>>
The targets for the step execution.
target_location: Option<TargetLocation>
The combination of Amazon Web Services Regions and Amazon Web Services accounts targeted by the current Automation execution.
triggered_alarms: Option<Vec<AlarmStateInformation>>
The CloudWatch alarms that were invoked by the automation.
parent_step_details: Option<ParentStepDetails>
Information about the parent step.
Implementations§
Source§impl StepExecution
impl StepExecution
Sourcepub fn action(&self) -> Option<&str>
pub fn action(&self) -> Option<&str>
The action this step performs. The action determines the behavior of the step.
Sourcepub fn timeout_seconds(&self) -> Option<i64>
pub fn timeout_seconds(&self) -> Option<i64>
The timeout seconds of the step.
Sourcepub fn on_failure(&self) -> Option<&str>
pub fn on_failure(&self) -> Option<&str>
The action to take if the step fails. The default value is Abort
.
Sourcepub fn max_attempts(&self) -> Option<i32>
pub fn max_attempts(&self) -> Option<i32>
The maximum number of tries to run the action of the step. The default value is 1
.
Sourcepub fn execution_start_time(&self) -> Option<&DateTime>
pub fn execution_start_time(&self) -> Option<&DateTime>
If a step has begun execution, this contains the time the step started. If the step is in Pending status, this field isn't populated.
Sourcepub fn execution_end_time(&self) -> Option<&DateTime>
pub fn execution_end_time(&self) -> Option<&DateTime>
If a step has finished execution, this contains the time the execution ended. If the step hasn't yet concluded, this field isn't populated.
Sourcepub fn step_status(&self) -> Option<&AutomationExecutionStatus>
pub fn step_status(&self) -> Option<&AutomationExecutionStatus>
The execution status for this step.
Sourcepub fn response_code(&self) -> Option<&str>
pub fn response_code(&self) -> Option<&str>
The response code returned by the execution of the step.
Sourcepub fn inputs(&self) -> Option<&HashMap<String, String>>
pub fn inputs(&self) -> Option<&HashMap<String, String>>
Fully-resolved values passed into the step before execution.
Sourcepub fn outputs(&self) -> Option<&HashMap<String, Vec<String>>>
pub fn outputs(&self) -> Option<&HashMap<String, Vec<String>>>
Returned values from the execution of the step.
Sourcepub fn response(&self) -> Option<&str>
pub fn response(&self) -> Option<&str>
A message associated with the response code for an execution.
Sourcepub fn failure_message(&self) -> Option<&str>
pub fn failure_message(&self) -> Option<&str>
If a step failed, this message explains why the execution failed.
Sourcepub fn failure_details(&self) -> Option<&FailureDetails>
pub fn failure_details(&self) -> Option<&FailureDetails>
Information about the Automation failure.
Sourcepub fn step_execution_id(&self) -> Option<&str>
pub fn step_execution_id(&self) -> Option<&str>
The unique ID of a step execution.
Sourcepub fn overridden_parameters(&self) -> Option<&HashMap<String, Vec<String>>>
pub fn overridden_parameters(&self) -> Option<&HashMap<String, Vec<String>>>
A user-specified list of parameters to override when running a step.
Sourcepub fn is_end(&self) -> Option<bool>
pub fn is_end(&self) -> Option<bool>
The flag which can be used to end automation no matter whether the step succeeds or fails.
Sourcepub fn is_critical(&self) -> Option<bool>
pub fn is_critical(&self) -> Option<bool>
The flag which can be used to help decide whether the failure of current step leads to the Automation failure.
Sourcepub fn valid_next_steps(&self) -> &[String]
pub fn valid_next_steps(&self) -> &[String]
Strategies used when step fails, we support Continue and Abort. Abort will fail the automation when the step fails. Continue will ignore the failure of current step and allow automation to run the next step. With conditional branching, we add step:stepName to support the automation to go to another specific step.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .valid_next_steps.is_none()
.
Sourcepub fn targets(&self) -> &[Target]
pub fn targets(&self) -> &[Target]
The targets for the step execution.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .targets.is_none()
.
Sourcepub fn target_location(&self) -> Option<&TargetLocation>
pub fn target_location(&self) -> Option<&TargetLocation>
The combination of Amazon Web Services Regions and Amazon Web Services accounts targeted by the current Automation execution.
Sourcepub fn triggered_alarms(&self) -> &[AlarmStateInformation]
pub fn triggered_alarms(&self) -> &[AlarmStateInformation]
The CloudWatch alarms that were invoked by the automation.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .triggered_alarms.is_none()
.
Sourcepub fn parent_step_details(&self) -> Option<&ParentStepDetails>
pub fn parent_step_details(&self) -> Option<&ParentStepDetails>
Information about the parent step.
Source§impl StepExecution
impl StepExecution
Sourcepub fn builder() -> StepExecutionBuilder
pub fn builder() -> StepExecutionBuilder
Creates a new builder-style object to manufacture StepExecution
.
Trait Implementations§
Source§impl Clone for StepExecution
impl Clone for StepExecution
Source§fn clone(&self) -> StepExecution
fn clone(&self) -> StepExecution
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for StepExecution
impl Debug for StepExecution
Source§impl PartialEq for StepExecution
impl PartialEq for StepExecution
impl StructuralPartialEq for StepExecution
Auto Trait Implementations§
impl Freeze for StepExecution
impl RefUnwindSafe for StepExecution
impl Send for StepExecution
impl Sync for StepExecution
impl Unpin for StepExecution
impl UnwindSafe for StepExecution
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> 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 moreSource§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
Source§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the foreground set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red()
and
green()
, which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg()
:
use yansi::{Paint, Color};
painted.fg(Color::White);
Set foreground color to white using white()
.
use yansi::Paint;
painted.white();
Source§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
Source§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
Source§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
Source§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
Source§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
Source§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
Source§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
Source§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the background set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red()
and
on_green()
, which have the same functionality but
are pithier.
§Example
Set background color to red using fg()
:
use yansi::{Paint, Color};
painted.bg(Color::Red);
Set background color to red using on_red()
.
use yansi::Paint;
painted.on_red();
Source§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
Source§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
Source§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
Source§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
Source§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
Source§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling Attribute
value
.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold()
and
underline()
, which have the same functionality
but are pithier.
§Example
Make text bold using attr()
:
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);
Make text bold using using bold()
.
use yansi::Paint;
painted.bold();
Source§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
Source§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi
Quirk
value
.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask()
and
wrap()
, which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk()
:
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);
Enable wrapping using wrap()
.
use yansi::Paint;
painted.wrap();
Source§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.
fn clear(&self) -> Painted<&T>
resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.Source§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the Condition
value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted
only when both stdout
and stderr
are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);