MLA-C01 Data Preparation for Machine Learning Practice Question
A data engineer needs to join two large datasets from Amazon S3: one containing customer demographics and another containing transaction history. The join key is `customer_id`. To minimize data shuffling and improve performance, the engineer decides to use Amazon SageMaker Processing with Spark. Which configuration should the engineer use?
⚠ Common exam trap
Watch out — candidates often assume bucketing alone (same number of buckets) is sufficient, but without co-location, Spark still performs a shuffle to align the data, so both conditions are required for a shuffle-free join.
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
✓
Use a bucketed join with the same number of buckets and co-location
Bucketed joins with the same number of buckets and co-location ensure that data with the same `customer_id` hash is physically stored together on the same nodes. This eliminates the need for expensive shuffles during the join, as Spark can perform the join locally within each executor, dramatically improving performance for large datasets in SageMaker Processing.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Use a bucketed join with the same number of buckets
Why it's wrong here
Without co-location, shuffling may still occur.
- ✗
Broadcast join the larger dataset
Why it's wrong here
Broadcast join is for small datasets, not both large.
- ✓
Use a bucketed join with the same number of buckets and co-location
Why this is correct
Bucketing with co-location allows Spark to perform the join without shuffling.
- ✗
Use a repartition on the join key before join
Why it's wrong here
Repartition reduces but does not eliminate shuffling.
Quick reference
AWS S3 Storage Class Comparison
| Storage Class | Min Duration | Retrieval | Use Case |
|---|---|---|---|
| S3 Standard | None | Immediate | Frequently accessed data |
| S3 Standard-IA | 30 days | Immediate | Infrequent access, rapid retrieval |
| S3 One Zone-IA | 30 days | Immediate | Non-critical infrequent data |
| S3 Intelligent-Tiering | None | Immediate–hours | Unknown or changing access patterns |
| S3 Glacier Instant | 90 days | Milliseconds | Archive with instant retrieval |
| S3 Glacier Flexible | 90 days | Minutes–hours | Archive, flexible retrieval |
| S3 Glacier Deep Archive | 180 days | Hours | Long-term compliance archive |
Go deeper
Related to this question
About these practice questions
One of 835 original MLA-C01 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. 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.