DynamoDB Flashcards
Eight things about DynamoDB?
- Fully managed
- Multi-region
- Multi-master
- Durable
- Built-in security
- Backup and restore
- In-memory caching
- Data is stored across multiple AZs
What are the 2 types of reads that DynamoDB provides?
- Strongly Consistent Reads
- Eventually Consistent Reads (Default)
The Key Value and Document database solution for AWS
DynamoDB (NoSQL)
What are the 3 components of a DynamoDB table?
- Keys
- Values
- Attributes
How many partitions does a DynamoDB database start off with?
1
How large can a single DynamoDB partition be? (GB)
10GB
The maximum read and write capacity units for a single DynamoDB partition
3000 Read Capacity Units, 1000 Write Capacity Units
These 2 components make up a composite primary key in DynamoDB
(kəmˈpɑzət)
Partition Key & Sort Key
In Dynamo DB, When using a simple primary key how many items can have the same partition key?
1
In Dynamo DB, What additional key component makes a primary key composite?
Sort key
- (The combination of the partition and the sort has to be unique) There is a secret internal hash function that decides which partition to write data
- New data is added into a partition with similar data, Eg. a category
- Partition Key: Category
- Sort Key: Name
In Dynamo DB, with composite keys multiple items share the same partition key (as long as their sort keys are different)
True or False
True.
- Partition Key: Country
- Sort Key: Citiy
Partition A: VE - CCS VE - MCBO Partition B: CL - STGO CL - CONCE
In Dynamo DB, The 2 methods of retrieving items from a DynamoDB table
Query & Scan
In Dynamo DB, By default what item attributes does a query return?
All attributes
This DynamoDB item retrieval method finds items based on primary key values.
Query
This DynamoDB item retrieval method checks all items, then returns one of more item using filters
Scan
- Scans are one of the most expensive ways to access data in DynamoDB
- Scans can be Slow