Skip to content

Instantly share code, notes, and snippets.

@adhorn
Created April 24, 2018 07:20
Show Gist options
  • Save adhorn/0cad81d5fa394b98824e1c540bc24588 to your computer and use it in GitHub Desktop.
Save adhorn/0cad81d5fa394b98824e1c540bc24588 to your computer and use it in GitHub Desktop.
Test DynamoDB Global Tables
aws dynamodb put-item \
--table-name MyGlobalTable \
--item '{"item_id": {"S":"foobar"}}' \
--region eu-west-1
# then you can test by fetching the item created from tthe other region enabled.
aws dynamodb get-item \
--table-name MyGlobalTable \
--key '{"item_id": {"S":"foobar"}}' \
--region eu-central-1
# this should output the following
{
"Item": {
"aws:rep:updatetime": {
"N": "1524554197.854001"
},
"item_id": {
"S": "foobar"
},
"aws:rep:updateregion": {
"S": "eu-west-1"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment