DynamoDB Time To Live (TTL)
5 Questions
0 Views

Choose a study mode

Play Quiz
Study Flashcards
Spaced Repetition
Chat to Lesson

Podcast

Play an AI-generated podcast conversation about this lesson

Questions and Answers

A DynamoDB table has TTL enabled. An item expires at 10:00 AM on January 1, 2024. When is the item guaranteed to be deleted?

  • Any time between 10:00 AM on January 1, 2024 and 10:00 AM on January 3, 2024 (correct)
  • 10:00 AM on January 3, 2024
  • 10:00 AM on January 2, 2024
  • DynamoDB Streams will record the deletion at 10:00 AM on January 1, 2024

You need to purge data older than 30 days from a DynamoDB table. Which approach is the most cost-effective?

  • Scan the table daily, identifying and deleting items older than 30 days using the DeleteItem operation.
  • Run a daily batch job that uses a parallel scan to identify and archive items older than 30 days to S3, then delete them.
  • Implement a Lambda function triggered by DynamoDB Streams to delete items older than 30 days.
  • Enable TTL on the table with a TTL attribute representing the expiration timestamp, set to 30 days in the past for old records. (correct)

An item in a DynamoDB table with TTL enabled is set to expire. What happens if the item is updated after its expiration time but before it is deleted?

  • The item will be updated, but the TTL expiration timestamp will reset to the current time.
  • The update will be rejected as the item is marked for deletion.
  • The item will be updated, and the deletion will still occur based on the original expiration timestamp. (correct)
  • The item will be updated, and the new values will be deleted according to the original expiration timestamp.

A developer is implementing TTL on a DynamoDB table. Which data type is suitable for storing the expiration timestamp?

<p>Number representing seconds since the Unix epoch (D)</p> Signup and view all the answers

You have enabled TTL on your DynamoDB table and want to track when items are deleted. How can you achieve this?

<p>Subscribe to DynamoDB Streams and process the stream records, looking for 'REMOVE' events with a <code>Service</code> deletion reason. (A)</p> Signup and view all the answers

Flashcards

DynamoDB TTL

A feature to automatically delete items from a DynamoDB table after a set time.

TTL Deletion Delay

Items are deleted ~48 hours after their expiration date.

TTL Cost Impact

Using TTL to delete items does not consume write throughput capacity.

TTL Timestamp Format

The expiration attribute must be in Unix Epoch timestamp format (seconds since 1970).

Signup and view all the flashcards

TTL and DynamoDB Streams

Deleted items appear in DynamoDB streams as service deletions.

Signup and view all the flashcards

Study Notes

  • Time To Live (TTL) allows automatic deletion of items from a table after a defined age.
  • Items are deleted approximately 48 hours after their expiration date.
  • TTL deletions do not consume write throughput, making it a cost-effective cleanup method.
  • Items pending deletion via TTL can still be updated.
  • The expiration timestamp should be in Unix Epoch format.
  • Deleted items appear in DynamoDB streams as service deletions.

Studying That Suits You

Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

Quiz Team

Description

DynamoDB Time To Live (TTL) enables automatic item deletion after a specified duration. Items are typically removed about 48 hours post-expiration. TTL deletions do not use write throughput and updating items resets their expiration.

More Like This

DynamoDB Fundamentals
280 questions

DynamoDB Fundamentals

FastGrowingBaltimore5920 avatar
FastGrowingBaltimore5920
DynamoDB APIs
18 questions

DynamoDB APIs

RationalStanza9319 avatar
RationalStanza9319
DynamoDB On-Demand Capacity Mode
16 questions
DynamoDB Accelerator (DAX)
18 questions

DynamoDB Accelerator (DAX)

RationalStanza9319 avatar
RationalStanza9319
Use Quizgecko on...
Browser
Browser