Bird
0
0

A Step Functions state machine uses a Choice state but always goes to the Default state even when inputs match Choice conditions. What is the likely error?

medium📝 Debug Q7 of 15
AWS - Serverless Architecture
A Step Functions state machine uses a Choice state but always goes to the Default state even when inputs match Choice conditions. What is the likely error?
AUsing 'Next' in the Default state
BChoice conditions use incorrect JSONPath expressions
CMissing 'End' field in the Choice state
DChoice state is not the StartAt state
Step-by-Step Solution
Solution:
  1. Step 1: Understand Choice state evaluation

    Choice conditions rely on correct JSONPath to evaluate input values properly.
  2. Step 2: Identify why Default is always chosen

    If JSONPath is wrong, conditions never match, so Default state runs every time.
  3. Final Answer:

    Choice conditions use incorrect JSONPath expressions -> Option B
  4. Quick Check:

    Wrong JSONPath = Default state chosen [OK]
Quick Trick: Validate JSONPath in Choice conditions carefully [OK]
Common Mistakes:
  • Assuming missing End causes default choice
  • Confusing StartAt with Choice state

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More AWS Quizzes