0.2.0 • Published 6 years ago

dynamodb-batch-insert v0.2.0

Weekly downloads
4
License
ISC
Repository
github
Last release
6 years ago

This is used to insert a batch of items into a dynamo db table with retries to get around the throughput limitations.

The code was copied as is from: https://stackoverflow.com/a/49169600/431522.

Here is an example of how to use it:

const batchInsert = require('dynamodb-batch-insert');
...
await batchInsert({
  tableName: 'People',
  list: [{ name: 'Hendrik' }, { name: 'Stewart' }],
  chunkSize: 10, // adjust to provisioned throughput. Max 25 (batchWrite dynamodb limit)
  msDelayBetweenChunks: 1000,
  documentClient,
});
...
0.2.0

6 years ago

0.1.0

6 years ago

0.0.1

6 years ago