hardMultiple ChoiceObjective-mapped
MLA-C01 Practice Question: A model deployed on SageMaker uses custom…
A model deployed on SageMaker uses custom inference code. The endpoint is showing intermittent 500 errors. CloudWatch logs reveal 'TimeoutError: Request timed out after 60 seconds'. The model takes on average 55 seconds to process. What is the most effective solution?
⚠ Common exam trap
Many candidates confuse the model container timeout (which applies to startup and health checks) with the per-request inference timeout, leading them to incorrectly choose Option B, while the real fix is to reduce latency through code optimization.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Optimize the inference code to reduce latency.
The model's average processing time of 55 seconds is dangerously close to the default SageMaker model container timeout of 60 seconds. Any transient spike in latency or resource contention can push the inference time beyond the timeout, causing intermittent 500 errors. Optimizing the inference code to reduce latency below the timeout threshold directly addresses the root cause by creating a safety margin, making the endpoint more resilient to normal variability.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Increase the invocation timeout in the SageMaker API call.
Why it's wrong here
The client-side timeout can be increased, but the server-side container timeout (default 60s) is what causes the error; increasing client timeout alone will not prevent the server-side timeout.
- ✗
Increase the SageMaker endpoint's model container timeout setting.
Why it's wrong here
While you can increase the container timeout via the SageMaker CreateEndpointConfig API, this masks the performance issue and may lead to resource exhaustion; optimization is preferred.
- ✓
Optimize the inference code to reduce latency.
Why this is correct
Reducing inference latency below the timeout threshold is the most direct and effective solution, as it addresses the root cause.
- ✗
Increase the endpoint's instance count.
Why it's wrong here
Increasing instances helps with concurrency but does not reduce per-request latency; the request still takes 55 seconds.
Go deeper
Related to this question
About these practice questions
Courseiva writes every MLA-C01 question from scratch — 835 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This MLA-C01 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the MLA-C01 exam.