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.200.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1c80f95e4986940a7e3ac9af1c142688d4fae74736ff59a3fd80f7a03891972e |
|
MD5 | 199931dfd035d4227d786d45d852c5d4 |
|
BLAKE2b-256 | 7d2df0f5c1f50d7bcbbb0262b2771485959cc4edbf12ca233f594961a00b676a |
Close
Hashes for pepperize.cdk_dynamodb_backup-0.0.200-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a1aa02978759ef4528d55870091565c2b3ffd29262be220665c866efe644bbee |
|
MD5 | 87ff25c4e71a394398a3837cb819450b |
|
BLAKE2b-256 | 27042908ac62950b056c620e7fd43515963af86cfbf172a5194a1467379a9217 |