In DynamoDB, after an item's TTL timestamp passes, when will DynamoDB delete that item?
Think about how background processes work asynchronously in cloud services.
DynamoDB's TTL feature deletes expired items asynchronously and typically within 48 hours after expiration, but exact timing is not guaranteed.
You have a DynamoDB table with TTL enabled on attribute expireAt. You run a Query operation immediately after an item's TTL timestamp has passed but before DynamoDB deletes it. What will the Query return?
Consider when DynamoDB physically removes expired items versus when they expire logically.
TTL expiration marks items for deletion, but they remain in the table until DynamoDB deletes them asynchronously. Queries still return these items until deletion.
Which of the following DynamoDB item attributes is correctly formatted for TTL to work?
Item example: { "id": "123", "expireAt": ??? }TTL expects a specific type of timestamp value.
DynamoDB TTL requires the attribute to be a Unix epoch time in seconds (a number), not a string or boolean.
You want expired items to be deleted as soon as possible after TTL expiration. Which approach can help reduce the delay?
Think about how you can react to changes in the table immediately.
Enabling DynamoDB Streams lets you detect expired items quickly and delete them manually, reducing delay beyond the default asynchronous TTL process.
You enabled TTL on your DynamoDB table with attribute expireAt. Some items have expired more than 48 hours ago but still appear in the table. What is the most likely reason?
Check the attribute format and presence carefully.
If the TTL attribute is missing or not a valid Unix epoch number, DynamoDB cannot identify the item as expired and will not delete it.