Data Stores Flashcards
What are the 3 types (concepts) of data store in AWS?
1) Persistent datastore
2) Transient datastore
3) Ephemeral datastore
Define persistent data storage and give 2 examples…
Data that is durable and sticks around after a reboot, restart or power cycles
e.g. Glacier, RDS
Define a transient data store and give 2 examples…
Data is just temporary stored and passed along to another process or persistent store
e.g. SQS, SNS
Define an ephemeral data store and give 2 examples…
Data is lost when stopped.
e.g. EC2 instance store, Elasticache- Memcached
What does IOPS stand for and what does it measure?
IOPS- Input output Operations Per Second
It is a measure of how fast we can read and write to a device
What does throughput measure?
It is the measure of how much data can be moved at a time
What are the two types of data storage consistency models?
1) ACID
2) BASE
What does ACID stand for?
Atomic- Transactions are all or nothing
Consistent- Transactions must be valid
Isolated- Transactions can’t mess with one another
Durable- Completed transactions must stick around
What does BASE stand for?
Basic Availablility- Values available even if stale
Soft-state- Might not be instantly consistent across stores
Eventually consistent- Will achieve consistency at some point
Why would you want a model (BASE) that was not consistent?
Because as accurate and precise ACID is they don’t scale very well.
BASE is not inconsistent just not parallel
What type of store is S3?
An Object store
What is the maximum object size in S3 and what is the largest object in a single PUT?
Max object size is 5TB
Largest single put 5GB
How can you increase the efficiency of uploads with files larger than 100MB?
You can use multi-part uploads
How are objects referenced in S3?
By a KEY, essentially a URL path like key.
s3:///finance/April/16/invoice.pdf
What is S3’s consistency model for read-after-writes? and what does this mean in lay terms?
S3 provides read-after-write consistency for PUTS of new objects
If a new file is added that S3 has never seen before once written you can read it immediately
What is S3’s consistency model for HEAD or GET requests of a KEY before the object exists? and what does this mean in lay terms?
HEAD or GET requests for a KEY before the object exists will result in eventual consistency.
Until an object has been fully written and replicated across AZs S3 will say that they don’t know what the object is. So I’ll let you read it eventually.
What is S3’s consistency model for overwrite PUTS and DELETES of objects? and what does this mean in lay terms?
S3 offers eventual consistency for overwrite PUTS (updates) and DELETES.
S3 will serve the original object until it has updated or deleted the file and has replicated this change across all other AZs. It will serve the updated/delete once it has been fully replicated eventually.
What is S3’s consistency model for updates to a single KEY? and what does this mean in lay terms?
Updates to a single KEY are atomic
Whoa there, only one person can update this object at a time. If I get two requests I’ll process them in order of their timestamps and you’ll see the updates as soon as I replicate them elsewhere.
What are the 3 methods of securing objects in an S3 bucket?
1) Resource-based (object ACL bucket policy)
2) User-based (IAM policies)
3) Object-based (Object ACL)
4) Optional MFA before delete
In what order does S3 evaluate the security access of an object?
User-based (IAM policy) > Resourced based (bucket policy) > Object-based (Object ACL)
What does versioning in S3 enable?
Enables “roll-back” and “un-delete” capabilities
Do you get charged for old versions of objects?
Yes
Why use MFA in S3?
1) If you require safeguarding against accidental deletion of an object
2) If you would like to change the versioning state of your bucket
Why use cross-region replication in S3?
1) increased durability
2) reduced latency
3) To meet compliance requirements