Bird
0
0

Given this Step Functions snippet, what is the next state after TaskA completes successfully?

medium📝 Predict Output Q13 of 15
AWS - Serverless Architecture
Given this Step Functions snippet, what is the next state after TaskA completes successfully?
{
  "StartAt": "TaskA",
  "States": {
    "TaskA": {
      "Type": "Task",
      "Resource": "arn:aws:lambda:region:123456789012:function:FunctionA",
      "Next": "TaskB"
    },
    "TaskB": {
      "Type": "Task",
      "Resource": "arn:aws:lambda:region:123456789012:function:FunctionB",
      "End": true
    }
  }
}
ATaskB
BTaskA
CEnd state
DNo next state defined
Step-by-Step Solution
Solution:
  1. Step 1: Read the "Next" field of TaskA

    The JSON shows "Next": "TaskB" for TaskA, meaning after TaskA finishes, the workflow moves to TaskB.
  2. Step 2: Confirm TaskB is defined

    TaskB is defined and marked with "End": true, so it is the final step after TaskA.
  3. Final Answer:

    TaskB -> Option A
  4. Quick Check:

    TaskA's "Next" = TaskB [OK]
Quick Trick: Check the "Next" field for the following state [OK]
Common Mistakes:
  • Assuming TaskA loops to itself
  • Thinking workflow ends after TaskA
  • Ignoring the "Next" field

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More AWS Quizzes