All Projects → shelfio → dynamodb-parallel-scan

shelfio / dynamodb-parallel-scan

Licence: MIT License
Scan large DynamoDB tables faster with parallelism

Programming Languages

typescript
32286 projects
javascript
184084 projects - #8 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to dynamodb-parallel-scan

angular-environment
AngularJS Environment Plugin
Stars: ✭ 78 (+271.43%)
Mutual labels:  npm-package
wakatime-client
🖥 JavaScript Client for https://wakatime.com/developers
Stars: ✭ 29 (+38.1%)
Mutual labels:  npm-package
ngx-smart-loader
Smart loader handler to manage loaders everywhere in Angular apps.
Stars: ✭ 28 (+33.33%)
Mutual labels:  npm-package
midtrans-node
Unoffficial Midtrans Payment API Client for Node JS | Alternative for Midtrans Official Module | https://midtrans.com
Stars: ✭ 15 (-28.57%)
Mutual labels:  npm-package
js-types
List of JavaScript types
Stars: ✭ 74 (+252.38%)
Mutual labels:  npm-package
request-extra
⚡️ Extremely stable HTTP request module built on top of libcurl with retries, timeouts and callback API
Stars: ✭ 14 (-33.33%)
Mutual labels:  npm-package
komit
An interactive prompt for conventional commit messages that doesn't get in your way. Designed to run as a git hook.
Stars: ✭ 29 (+38.1%)
Mutual labels:  npm-package
aws-appsync-iot-core-realtime-dashboard
This sample application demonstrates a React based web dashboard receiving real-time updates from IoT sensors. The solution is built with AWS AppSync, AWS Amplify, Amazon Location Service, and AWS IoT Core technologies.
Stars: ✭ 75 (+257.14%)
Mutual labels:  dynamodb
dynamodb-api
DynamoDB API wrapper gem. like SQL and simply.
Stars: ✭ 15 (-28.57%)
Mutual labels:  dynamodb
aws-dynamodb-java-example-local-testing
Example Gradle Java project for using AWS DynamoDB for local testing.
Stars: ✭ 22 (+4.76%)
Mutual labels:  dynamodb
beginner-windows-npm-gulp-webdev-tutorial
Beginner guide for users on web development with node.js/npm + gulp terminal commands. You'll learn how to use other terminal commands like git, gulp, bower, yarn, and more!
Stars: ✭ 40 (+90.48%)
Mutual labels:  npm-package
notifyme
react-notification-timeline is a react based component helps in managing the notification in time-based manner.
Stars: ✭ 94 (+347.62%)
Mutual labels:  npm-package
npm-update-check-action
npm new package version check action for GitHub Actions.
Stars: ✭ 17 (-19.05%)
Mutual labels:  npm-package
unique-names-generator
Generate unique and memorable name strings
Stars: ✭ 356 (+1595.24%)
Mutual labels:  npm-package
MeeInk
Material Design click effect
Stars: ✭ 33 (+57.14%)
Mutual labels:  npm-package
tinder-client
❤️ NodeJS Tinder Client
Stars: ✭ 50 (+138.1%)
Mutual labels:  npm-package
unity-activate
A tool to activate Unity license.
Stars: ✭ 29 (+38.1%)
Mutual labels:  npm-package
dynamodb-copy-table
A simple python script to copy dynamodb table (useful for achieving renaming of table)
Stars: ✭ 115 (+447.62%)
Mutual labels:  dynamodb
netty-finder
☎️ This script checks a Nigerian telephone number and detects which network it belongs to.
Stars: ✭ 44 (+109.52%)
Mutual labels:  npm-package
kafka-connect-dynamodb
Kafka Connector for DynamoDB [unmaintained]
Stars: ✭ 30 (+42.86%)
Mutual labels:  dynamodb

dynamodb-parallel-scan CircleCI npm (scoped)

Scan DynamoDB table concurrently (up to 1,000,000 segments), recursively read all items from every segment

Install

$ yarn add @shelf/dynamodb-parallel-scan

Usage

Fetch everything at once

const {parallelScan} = require('@shelf/dynamodb-parallel-scan');

(async () => {
  const items = await parallelScan(
    {
      TableName: 'files',
      FilterExpression: 'attribute_exists(#fileSize)',
      ExpressionAttributeNames: {
        '#fileSize': 'fileSize',
      },
      ProjectionExpression: 'fileSize',
    },
    {concurrency: 1000}
  );

  console.log(items);
})();

Use as async generator (or streams)

Note: this stream doesn't implement backpressure mechanism just yet, so memory overflow could happen if you don't consume stream fast enough.

const {parallelScanAsStream} = require('@shelf/dynamodb-parallel-scan');

(async () => {
  const stream = await parallelScanAsStream(
    {
      TableName: 'files',
      FilterExpression: 'attribute_exists(#fileSize)',
      ExpressionAttributeNames: {
        '#fileSize': 'fileSize',
      },
      ProjectionExpression: 'fileSize',
    },
    {concurrency: 1000, chunkSize: 10000}
  );

  for await (const items of stream) {
    console.log(items); // 10k items here
  }
})();

Read

Publish

$ git checkout master
$ yarn version
$ yarn publish
$ git push origin master

License

MIT © Shelf

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].