Key Concepts
It is a no sql db that is fully managed.
A table contains items.
Item corresponds to a row in a traditional db. An item can have a max size of 400 Kb.
An item contains attributes. These correspond to columns.
We have a primary key .
A primary key identifies a row. Two items cannot have the same primary key.
There are 2 kinds of primary key. One is a simple key and the other a composite primary key. The simple key has a single partition key corresponding to an attribute.
Composite key has has a partition key and a sort key. It sorts things by the sort key. The sort key corresponds to an attribute.
A partition key is know as a hash attribute and the sort key is known as a range attribute. A partition is a storage area may corresponding to a hard drive. An item's partition key is used to decide the partition the item should be stored at. An hash is taken off the partition key to evaluate the partition.
Secondary Indexes
They are alternative keys . Can be global secondary index or local secondary index.
Global Secondary Index
Partition key and sort key different from the base table. Query has to search all the partitions for the item.
Local Secondary Index
Partition key is same and sort key is different. Query searches only the partition.
Read/Write Throughput
Eventually consistent
Immediate read may return stale data.
Strongly consistent
Reads same value even after immediate read.
Throughput
Max amount of capacity an application can read from an index.
RCU
Strongly consistent reads per second that are up to 4Kb in size.
WCU
Partitions and Data Distribution
Streams and Global Tables
Global Table
Data is synced across multiple regions.
Backup and Restore