Git Product home page Git Product logo

dynamodb-tooling's Introduction

Social Card of this repo

npm version GitHub Actions Commitizen friendly

DynamoDB Goodies

Features

  • Zero-config DynamoDB setup
  • Local development with SSL support (wip)
  • DynamoDB Toolbox integration

Install

bun install -d dynamodb-tooling

Get Started

Getting started with the DynamoDB Tooling is easy. Just import dynamoDb and get going:

import { dynamoDb } from 'dynamodb-tooling'

interface LaunchOptions {
  port: number
  dbPath?: string
  additionalArgs?: string[]
  verbose?: boolean
  detached?: boolean
  javaOpts?: string
}

const childProcess = await dynamoDb.launch(options)
dynamoDb.stopChild(childProcess)
dynamoDb.stop(options.port)
dynamoDb.relaunch()

dynamoDb.configureInstaller()
await dynamoDb.install()

Example

import { dynamoDb } from 'dynamodb-tooling'

const port = 8000
// if you want to share with Bun Shell
await dynamoDb.launch({
  port,
  additionalArgs: ['-sharedDb'],
})
// do your tests / trigger your logic
dynamoDb.stop(port)

Alternatively, you can use it as a detached server:

const port = 8000
const child = await dynamoDb.launch({ port })
// trigger your logic
await dynamoDb.stopChild(child)

Configuration

The client can be configured using a dynamodb.config.ts (or dynamodb.config.js) file and it will be automatically loaded.

// dynamodb.config.ts (or dynamodb.config.js)
export default {
  installPath: path.join(os.tmpdir(), 'dynamodb-local'),
  downloadUrl: 'https://d1ni2b6xgvw0s0.cloudfront.net/v2.x/dynamodb_local_latest.tar.gz', // the official download URL
}

Testing

bun test

Changelog

Please see our releases page for more information on what has changed recently.

Contributing

Please review the Contributing Guide for details.

Community

For help, discussion about best practices, or any other conversation that would benefit from being searchable:

Discussions on GitHub

For casual chit-chat with others using this package:

Join the Stacks Discord Server

Postcardware

Stacks OSS will always stay open-sourced, and we will always love to receive postcards from wherever Stacks is used! And we also publish them on our website. Thank you, Spatie.

Our address: Stacks.js, 5710 Crescent Park #107, Playa Vista 90094, CA, USA ๐ŸŒŽ

Sponsors

We would like to extend our thanks to the following sponsors for funding Stacks development. If you are interested in becoming a sponsor, please reach out to us.

Credits

License

The MIT License (MIT). Please see LICENSE for more information.

Made with ๐Ÿ’™

dynamodb-tooling's People

Contributors

chrisbbreuer avatar renovate[bot] avatar

Stargazers

 avatar

Watchers

 avatar  avatar

dynamodb-tooling's Issues

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Repository problems

These problems occurred while renovating this repository. View logs.

  • WARN: Using npm packages for Renovate presets is now deprecated. Please migrate to repository-based presets instead.

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

bun
package.json
  • dynamodb-toolbox ^0.9.2
  • @antfu/eslint-config ^2.13.2
  • @commitlint/cli ^19.2.1
  • @types/bun ^1.0.12
  • @types/tar ^6.1.12
  • bumpp ^9.4.0
  • bun-plugin-dts-auto ^0.11.1
  • c12 ^1.10.0
  • changelogen ^0.5.5
  • commitizen ^4.3.0
  • cz-git ^1.9.1
  • lint-staged ^15.2.2
  • simple-git-hooks ^2.11.1
  • tar ^6.2.1
  • typescript ^5.4.4
github-actions
.github/workflows/ci.yml
  • actions/checkout v4
  • oven-sh/setup-bun v1
  • actions/cache v4
  • actions/checkout v4
  • oven-sh/setup-bun v1
  • actions/cache v4
  • actions/checkout v4
  • oven-sh/setup-bun v1
  • actions/cache v4
.github/workflows/release.yml
  • actions/checkout v4
  • actions/setup-node v4
  • oven-sh/setup-bun v1
  • actions/cache v4

  • Check this box to trigger a request for Renovate to run again on this repository

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.