Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Amazon DynamoDB via CloudFormation - point in time recovery

Is it possible to specify Point In Time Recovery for an Amazon DynamoDB table created via CloudFormation? I've been looking through the docs and user guide and haven't found anything useful yet.

like image 941
ethrbunny Avatar asked May 22 '18 15:05

ethrbunny


People also ask

How do I enable DynamoDB point-in-time recovery?

Navigate to DynamoDB. In the left navigation, select Tables. Select the desired table and in the Overview section, Enable Point-in-time recovery. Click Enable.

What is DynamoDB point-in-time recovery?

Amazon DynamoDB enables you to back up your table data continuously by using point-in-time recovery (PITR). When you enable PITR, DynamoDB backs up your table data automatically with per-second granularity so that you can restore to any given second in the preceding 35 days.

How long does it take to restore a DynamoDB table?

It can take up to 20 minutes (even if the table is empty) to perform all the actions to create the new table and initiate the restore process. For tables with even data distribution across your primary keys, the restore time is proportional to the largest single partition by item count and not the overall table size.


1 Answers

This is now possible with cloud formation by adding a PointInTimeRecoverySpecification to your cloud formation template.

Example:

  Type: 'AWS::DynamoDB::Table'
  Properties:
    TableName: MyTable
    PointInTimeRecoverySpecification:
      PointInTimeRecoveryEnabled: true
    ...
like image 138
gfv Avatar answered Oct 03 '22 17:10

gfv