Raw log files in S3 must be deleted automatically 400 days after they are created. What do you configure?
- Exam domain
- Data Store Management26% of the exam
- Difficulty
- Easy
- In this mock
- 23 questions on this domainPractise this domain
Why the exam asks this
Task Statement 2.3: Manage the lifecycle of data.
Objective in the exam guide: Expire data when it reaches a specific age by using S3 Lifecycle policies.
Keeping data longer than needed costs money and can break retention rules. Expiration enforces the retention period automatically.
Why B is the answer
An S3 Lifecycle expiration action at 400 days
Lifecycle expiration actions delete objects when they reach a set age.
Remember: Delete by age: an S3 Lifecycle expiration.
How it works
An S3 Lifecycle rule can expire objects, deleting them, once they reach a set age.
It can be combined with transitions to cheaper classes earlier in the object's life.
In versioned buckets, expiring noncurrent versions needs a separate action.
Clues in the question
The words that point to the answer, and what each one tells you.
- Deleted automatically 400 days after creation
- A lifecycle expiration.
In detail
- Lifecycle rules can combine transitions and expiration.
- With versioning, noncurrent versions need their own expiration rule.
Side by side with look-alikes
| Lifecycle action | Effect |
|---|---|
| Expiration | Deletes objects at an age |
| Transition | Moves to a cheaper class |
| Noncurrent expiration | Deletes old versions |
Every option, checked
Knowing why each wrong option fails is how you rule it out on exam day.
A. A CloudWatch alarmWrong
Alarms notify; they do not delete.
B. An S3 Lifecycle expiration action at 400 daysRight
Delete by age: an S3 Lifecycle expiration.
C. A storage class change onlyWrongMost tempting
A transition moves objects to a cheaper class but keeps them.
Why it tempts: Transitions are part of lifecycle rules too. But they keep the data; they do not delete it.
D. A Glue crawlerWrong
Crawlers catalog data; they do not delete it.
In practice
- Match expiration to the documented retention policy.
Use case
An illustrative scenario, not a real incident.
A rule moves logs to a colder class at 90 days and expires them at 400.
See how it works
stateDiagram-v2 [*] --> Standard: Created Standard --> Colder: Day 90 transition Colder --> Deleted: Day 400 expiration Deleted --> [*]
How to read this chart
- It starts at "Standard".
- From "Standard", "Day 90 transition" moves it to "Colder".
- From "Colder", "Day 400 expiration" moves it to "Deleted".
- It ends at "Deleted".