0
0
DynamoDBquery~5 mins

TTL behavior and timing in DynamoDB - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What does TTL stand for in DynamoDB?
TTL stands for Time To Live. It is a feature that automatically deletes expired items from a DynamoDB table.
Click to reveal answer
beginner
How does DynamoDB determine when to delete an item using TTL?
DynamoDB checks the timestamp attribute you specify for TTL. When the current time passes this timestamp, the item becomes eligible for deletion.
Click to reveal answer
intermediate
Does DynamoDB delete expired items immediately after the TTL timestamp passes?
No. DynamoDB deletes expired items within 48 hours after the TTL timestamp passes. The deletion is not immediate but happens asynchronously.
Click to reveal answer
intermediate
What happens if you update the TTL attribute of an item before it expires?
If you update the TTL attribute to a new future timestamp, DynamoDB will use the updated timestamp to determine when to delete the item. This can delay or cancel the deletion.
Click to reveal answer
advanced
Can you recover an item after DynamoDB deletes it due to TTL expiration?
No. Once DynamoDB deletes an item due to TTL expiration, it cannot be recovered. You should back up important data before it expires.
Click to reveal answer
What is the main purpose of TTL in DynamoDB?
AAutomatically delete expired items
BEncrypt data at rest
CBackup data regularly
DImprove query speed
When does DynamoDB delete an item after its TTL timestamp has passed?
AImmediately
BAfter 7 days
CWithin 48 hours
DOnly when manually triggered
Which attribute type must the TTL attribute be in DynamoDB?
AString
BList
CBoolean
DNumber (Unix epoch time in seconds)
If you remove the TTL attribute from an item before expiration, what happens?
AItem is deleted immediately
BItem will not be deleted by TTL
CItem is archived
DItem is locked
Can TTL be used to trigger custom actions when an item expires?
AYes, via DynamoDB Streams and Lambda
BNo, TTL only deletes items
CYes, directly within DynamoDB
DNo, TTL archives items instead
Explain how TTL works in DynamoDB and its timing behavior.
Think about how DynamoDB knows when to delete and when it actually deletes.
You got /4 concepts.
    Describe what happens if you update or remove the TTL attribute on an item before it expires.
    Consider how DynamoDB uses the TTL attribute to decide deletion.
    You got /3 concepts.