I see that objects are deleted in 48 hours after TTL expires. But do they get deleted at the same time if they have matching TTL?
I've looked over the DynamoDB documentation, but I can't find the answer to that.
As per AWS docs, there are two background processes that take place when TTL is configured. The first background process marks the items for expiry based on the user defined attribute and the second background process scans for expired items and deletes them.
So, objects with matching TTL are not deleted at the same time.
Below is a paragraph from the AWS docs shared
Depending on the size and activity level of a table, the actual delete operation of an expired item can vary. Because TTL is meant to be a background process, the nature of the capacity used to expire and delete items via TTL is variable (but free of charge). TTL typically deletes expired items within 48 hours of expiration.