Empty S3 Bucket and DynamoDB Table Using the AWS SDK
Ever need to just completely clear out an S3 bucket or a DynamoDB table using the AWS SDK? Think it will be one SDK call and then you’re done? Not so! The S3 console has an Empty button for each bucket and the AWS CLI has a aws s3 rm --recursive command. But the console doesn’t lend itself to automation and the CLI command doesn’t work for buckets with object versioning turned on.