testdynamo

command
v0.1.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 13, 2026 License: MIT Imports: 14 Imported by: 0

README

testdynamo

A SAM-deployed Lambda that serves the testv1.Test aggregate over API Gateway.

Prerequisites

  • AWS SAM CLI (brew install aws-sam-cli)
  • AWS credentials configured (aws configure or SSO)
  • Tables created via testdynamo-setup (see below)

Table Setup

# Create tables (events + aggregates) with TTL, PITR, deletion protection
go run ./cmd/testdynamo-setup create

# Fix existing tables missing TTL or PITR
go run ./cmd/testdynamo-setup fix

# Check table configuration
go run ./cmd/testdynamo-setup status

Override table names or endpoint via environment:

EVENTS_TABLE=my-events AGGREGATES_TABLE=my-aggregates go run ./cmd/testdynamo-setup create
AWS_ENDPOINT_URL=http://localhost:8000 go run ./cmd/testdynamo-setup create  # DynamoDB Local

Deploy

cd cmd/testdynamo

# First deploy (interactive — prompts for stack name, region, etc.)
sam build && sam deploy --guided

# Subsequent deploys (uses saved samconfig.toml)
sam build && sam deploy

Tear Down

# Disable deletion protection first
go run ./cmd/testdynamo-setup disable-protection

# Delete tables
go run ./cmd/testdynamo-setup delete

# Delete the SAM stack
sam delete --stack-name <your-stack-name>

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL