Backup and restore AWS DynamoDB Table to AWS S3 Bucket with AWS Data Pipeline.
Project description
CDK DynamoDB Backup & Restore
Backup and restore AWS DynamoDB Table with AWS Data Pipeline.
Install
TypeScript
npm install @pepperize/cdk-dynamodb-backup
or
yarn add @pepperize/cdk-dynamodb-backup
Python
pip install pepperize.cdk-dynamodb-backup
C# / .Net
dotnet add package Pepperize.CDK.DynamodbBackup
Java
<dependency>
<groupId>com.pepperize</groupId>
<artifactId>cdk-dynamodb-backup</artifactId>
<version>${cdkDynamodbBackup.version}</version>
</dependency>
Usage
See API.md.
Backup
Export data from AWS DynamoDB to AWS S3
const table = new aws_dynamodb.Table(stack, "Table", {
partitionKey: { name: "id", type: dynamodb.AttributeType.STRING },
});
const bucket = new aws_s3.Bucket(stack, "Bucket", {});
// When
new DataPipelineBackup(stack, "Account", {
table: table,
backupBucket: bucket,
});
See Exporting Data From DynamoDB to Amazon S3
Restore
Import data from AWS S3 into AWS DynamoDB
const table = new aws_dynamodb.Table(stack, "Table", {
partitionKey: { name: "id", type: dynamodb.AttributeType.STRING },
});
const bucket = new aws_s3.Bucket(stack, "Bucket", {});
// When
new DataPipelineRestore(stack, "Restore", {
table: table,
restoreBucket: bucket,
restoreFolder: "/prefix/to/folder/with/manifest",
});
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for pepperize.cdk-dynamodb-backup-0.0.30.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4987123a744f4af01fc2c7d3c734dd61d8a954fd1fc47042145dbab36eb0622c |
|
MD5 | e85e0807312ee1119294817f613213eb |
|
BLAKE2b-256 | 2c8c63e1156474fb6a0bf5d6d6c4038f4f69391eeb72b8a2d9ca93f35b7ca2f3 |
Close
Hashes for pepperize.cdk_dynamodb_backup-0.0.30-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 84cb326188cb7c5d6c8daddff17394c38b539c0f11db2573893150e52f2d8285 |
|
MD5 | 8bf96171acd83ab1a24a2e164c8855ac |
|
BLAKE2b-256 | d30d3970de6d42ef81fab786d0859af52e16da636f084f79184c4b78d290ffc1 |