Interface StepExecution.Builder

    • Method Detail

      • stepName

        StepExecution.Builder stepName​(String stepName)

        The name of this execution step.

        Parameters:
        stepName - The name of this execution step.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • action

        StepExecution.Builder action​(String action)

        The action this step performs. The action determines the behavior of the step.

        Parameters:
        action - The action this step performs. The action determines the behavior of the step.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • timeoutSeconds

        StepExecution.Builder timeoutSeconds​(Long timeoutSeconds)

        The timeout seconds of the step.

        Parameters:
        timeoutSeconds - The timeout seconds of the step.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • onFailure

        StepExecution.Builder onFailure​(String onFailure)

        The action to take if the step fails. The default value is Abort.

        Parameters:
        onFailure - The action to take if the step fails. The default value is Abort.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • maxAttempts

        StepExecution.Builder maxAttempts​(Integer maxAttempts)

        The maximum number of tries to run the action of the step. The default value is 1.

        Parameters:
        maxAttempts - The maximum number of tries to run the action of the step. The default value is 1.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • executionStartTime

        StepExecution.Builder executionStartTime​(Instant executionStartTime)

        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.

        Parameters:
        executionStartTime - 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.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • executionEndTime

        StepExecution.Builder executionEndTime​(Instant executionEndTime)

        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.

        Parameters:
        executionEndTime - 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.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • responseCode

        StepExecution.Builder responseCode​(String responseCode)

        The response code returned by the execution of the step.

        Parameters:
        responseCode - The response code returned by the execution of the step.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • inputs

        StepExecution.Builder inputs​(Map<String,​String> inputs)

        Fully-resolved values passed into the step before execution.

        Parameters:
        inputs - Fully-resolved values passed into the step before execution.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • outputs

        StepExecution.Builder outputs​(Map<String,​? extends Collection<String>> outputs)

        Returned values from the execution of the step.

        Parameters:
        outputs - Returned values from the execution of the step.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • response

        StepExecution.Builder response​(String response)

        A message associated with the response code for an execution.

        Parameters:
        response - A message associated with the response code for an execution.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • failureMessage

        StepExecution.Builder failureMessage​(String failureMessage)

        If a step failed, this message explains why the execution failed.

        Parameters:
        failureMessage - If a step failed, this message explains why the execution failed.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • failureDetails

        StepExecution.Builder failureDetails​(FailureDetails failureDetails)

        Information about the Automation failure.

        Parameters:
        failureDetails - Information about the Automation failure.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • stepExecutionId

        StepExecution.Builder stepExecutionId​(String stepExecutionId)

        The unique ID of a step execution.

        Parameters:
        stepExecutionId - The unique ID of a step execution.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • overriddenParameters

        StepExecution.Builder overriddenParameters​(Map<String,​? extends Collection<String>> overriddenParameters)

        A user-specified list of parameters to override when running a step.

        Parameters:
        overriddenParameters - A user-specified list of parameters to override when running a step.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • isEnd

        StepExecution.Builder isEnd​(Boolean isEnd)

        The flag which can be used to end automation no matter whether the step succeeds or fails.

        Parameters:
        isEnd - The flag which can be used to end automation no matter whether the step succeeds or fails.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • nextStep

        StepExecution.Builder nextStep​(String nextStep)

        The next step after the step succeeds.

        Parameters:
        nextStep - The next step after the step succeeds.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • isCritical

        StepExecution.Builder isCritical​(Boolean isCritical)

        The flag which can be used to help decide whether the failure of current step leads to the Automation failure.

        Parameters:
        isCritical - The flag which can be used to help decide whether the failure of current step leads to the Automation failure.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • validNextSteps

        StepExecution.Builder validNextSteps​(Collection<String> validNextSteps)

        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.

        Parameters:
        validNextSteps - 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.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • validNextSteps

        StepExecution.Builder validNextSteps​(String... validNextSteps)

        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.

        Parameters:
        validNextSteps - 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.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • targets

        StepExecution.Builder targets​(Collection<Target> targets)

        The targets for the step execution.

        Parameters:
        targets - The targets for the step execution.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • targets

        StepExecution.Builder targets​(Target... targets)

        The targets for the step execution.

        Parameters:
        targets - The targets for the step execution.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • targets

        StepExecution.Builder targets​(Consumer<Target.Builder>... targets)

        The targets for the step execution.

        This is a convenience method that creates an instance of the Target.Builder avoiding the need to create one manually via Target.builder().

        When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to #targets(List).

        Parameters:
        targets - a consumer that will call methods on Target.Builder
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        #targets(java.util.Collection)
      • targetLocation

        StepExecution.Builder targetLocation​(TargetLocation targetLocation)

        The combination of Amazon Web Services Regions and Amazon Web Services accounts targeted by the current Automation execution.

        Parameters:
        targetLocation - The combination of Amazon Web Services Regions and Amazon Web Services accounts targeted by the current Automation execution.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • triggeredAlarms

        StepExecution.Builder triggeredAlarms​(Collection<AlarmStateInformation> triggeredAlarms)

        The CloudWatch alarms that were invoked by the automation.

        Parameters:
        triggeredAlarms - The CloudWatch alarms that were invoked by the automation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • triggeredAlarms

        StepExecution.Builder triggeredAlarms​(AlarmStateInformation... triggeredAlarms)

        The CloudWatch alarms that were invoked by the automation.

        Parameters:
        triggeredAlarms - The CloudWatch alarms that were invoked by the automation.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • parentStepDetails

        StepExecution.Builder parentStepDetails​(ParentStepDetails parentStepDetails)

        Information about the parent step.

        Parameters:
        parentStepDetails - Information about the parent step.
        Returns:
        Returns a reference to this object so that method calls can be chained together.