Skip to content

Instantly share code, notes, and snippets.

@oscaroceguera
Created January 18, 2022 00:46
Show Gist options
  • Save oscaroceguera/e35f94112069e975856bd4b70b82e576 to your computer and use it in GitHub Desktop.
Save oscaroceguera/e35f94112069e975856bd4b70b82e576 to your computer and use it in GitHub Desktop.
create players table for dynamoddb
{
"TableName": "players",
"AttributeDefinitions": [
{
"AttributeName": "mytype",
"AttributeType": "S"
},
{
"AttributeName": "myposition",
"AttributeType": "S"
},
{
"AttributeName": "playerId",
"AttributeType": "S"
}
],
"GlobalSecondaryIndexes": [
{
"IndexName": "playerId-index",
"KeySchema": [
{
"AttributeName": "playerId",
"KeyType": "HASH"
}
],
"Projection": {
"ProjectionType": "ALL"
},
"ProvisionedThroughput": {
"ReadCapacityUnits": 10,
"WriteCapacityUnits": 10
}
},
{
"IndexName": "myposition-playerId-index",
"KeySchema": [
{
"AttributeName": "myposition",
"KeyType": "HASH"
},
{
"AttributeName": "playerId",
"KeyType": "RANGE"
}
],
"Projection": {
"ProjectionType": "ALL"
},
"ProvisionedThroughput": {
"ReadCapacityUnits": 10,
"WriteCapacityUnits": 10
}
}
],
"KeySchema": [
{
"AttributeName": "mytype",
"KeyType": "HASH"
},
{
"AttributeName": "playerId",
"KeyType": "RANGE"
}
],
"ProvisionedThroughput": {
"ReadCapacityUnits": 10,
"WriteCapacityUnits": 10
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment