Class TestOperation

java.lang.Object
software.amazon.lambda.durable.testing.TestOperation

public class TestOperation extends Object
Wrapper for AWS SDK Operation providing convenient access methods.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns the current retry attempt number (0-based), defaulting to 0 if not available.
    software.amazon.awssdk.services.lambda.model.CallbackDetails
    Returns the callback details, or null if this is not a callback operation.
    software.amazon.awssdk.services.lambda.model.ChainedInvokeDetails
    Returns the chained invoke details, or null if this is not a chained invoke operation.
    software.amazon.awssdk.services.lambda.model.ContextDetails
    Returns the context details, or null if this operation is not a context.
    Returns the duration of the operation
    software.amazon.awssdk.services.lambda.model.ErrorObject
    Returns the step error, or null if the step succeeded or this is not a step operation.
    List<software.amazon.awssdk.services.lambda.model.Event>
    Returns the raw history events associated with this operation.
    software.amazon.awssdk.services.lambda.model.ExecutionDetails
    Returns the execution details, or null if this operation is not an EXECUTION operation.
    Returns the operation name.
    software.amazon.awssdk.services.lambda.model.OperationStatus
    Returns the current status of this operation (e.g.
    software.amazon.awssdk.services.lambda.model.StepDetails
    Returns the step details, or null if this is not a step operation.
    <T> T
    Deserializes and returns the step result as the given type.
    <T> T
    Deserializes and returns the step result using a TypeToken for generic types.
    Returns the operation's subtype
    software.amazon.awssdk.services.lambda.model.OperationType
    Returns the operation type (STEP, WAIT, CALLBACK, etc.).
    software.amazon.awssdk.services.lambda.model.WaitDetails
    Returns the wait details, or null if this is not a wait operation.
    boolean
    Returns true if the operation has completed (either succeeded or failed).

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • getEvents

      public List<software.amazon.awssdk.services.lambda.model.Event> getEvents()
      Returns the raw history events associated with this operation.
    • getName

      public String getName()
      Returns the operation name.
    • getStatus

      public software.amazon.awssdk.services.lambda.model.OperationStatus getStatus()
      Returns the current status of this operation (e.g. STARTED, SUCCEEDED, FAILED).
    • getType

      public software.amazon.awssdk.services.lambda.model.OperationType getType()
      Returns the operation type (STEP, WAIT, CALLBACK, etc.).
    • getSubtype

      public String getSubtype()
      Returns the operation's subtype
    • isCompleted

      public boolean isCompleted()
      Returns true if the operation has completed (either succeeded or failed).
    • getDuration

      public Duration getDuration()
      Returns the duration of the operation
    • getStepDetails

      public software.amazon.awssdk.services.lambda.model.StepDetails getStepDetails()
      Returns the step details, or null if this is not a step operation.
    • getWaitDetails

      public software.amazon.awssdk.services.lambda.model.WaitDetails getWaitDetails()
      Returns the wait details, or null if this is not a wait operation.
    • getCallbackDetails

      public software.amazon.awssdk.services.lambda.model.CallbackDetails getCallbackDetails()
      Returns the callback details, or null if this is not a callback operation.
    • getChainedInvokeDetails

      public software.amazon.awssdk.services.lambda.model.ChainedInvokeDetails getChainedInvokeDetails()
      Returns the chained invoke details, or null if this is not a chained invoke operation.
    • getContextDetails

      public software.amazon.awssdk.services.lambda.model.ContextDetails getContextDetails()
      Returns the context details, or null if this operation is not a context.
    • getExecutionDetails

      public software.amazon.awssdk.services.lambda.model.ExecutionDetails getExecutionDetails()
      Returns the execution details, or null if this operation is not an EXECUTION operation.
    • getStepResult

      public <T> T getStepResult(Class<T> type)
      Deserializes and returns the step result as the given type.
    • getStepResult

      public <T> T getStepResult(TypeToken<T> type)
      Deserializes and returns the step result using a TypeToken for generic types.
    • getError

      public software.amazon.awssdk.services.lambda.model.ErrorObject getError()
      Returns the step error, or null if the step succeeded or this is not a step operation.
    • getAttempt

      public int getAttempt()
      Returns the current retry attempt number (0-based), defaulting to 0 if not available.