8. RDS + Aurora + ElastiCache Flashcards
What are the steps to encrypt an unencrypted RDS database?
- Create a snapshot of the unencrypted database
- Copy the snapshot and enable encryption for the snapshot
- Restore the database from the encrypted snapshot
- Migrate applications to the new database, and delete the old database
What databases are supported by ElastiCache?
Redis and Memcached
What features come with Redis?
- Multi-AZ with Auto-Failover
- Read replicas to scale reads and have high availability
- Data Durability using AOF persistence
- Backup and restore features
What features come with Memcached?
- Multi-node for partitioning of data (sharding)
- No high availability (replication)
- Non-persistent
- No backup and restore
- Multi-threaded architecture
What databases does RDS support?
- Postgres
- MySQL
- MariaDB
- Oracle
- Microsoft SQL Server
- Aurora (AWS proprietary database)
You have set up read replicas on your RDS database, but users are complaining that upon updating their social media posts, they do not see their updated posts right away. What is a possible cause for this?
Read replicas have asynchronous replication, therefore it’s likely your users will only read eventual consistency
You are running an ElastiCache Redis cluster which you want to ensure is high availability. What should you do?
Enable multi-AZ
Which databases does Amazon Aurora support?
MySQL and PostgreSQL
How many Aurora Read Replicas can you have in a single Aurora DB Cluster?
15
How many Read Replicas can you have in a single RDS database?
15
How does the cost of Aurora compare to RDS?
Aurora costs more than RDS (20% more) but is more efficient
What is the Aurora Backtrack feature?
Backtrack allows you to restore data at any point in time without using backups
What are the 3 ways in which cache evictions can occur?
- You delete the item explicitly in the cache
- Item is evicted bc the memory is full and it’s not recently used
- You set an item time-to-live (TTL)
If too many eviction happen due to memory, what you should you do?
Scale up or out
What are the pros and cons of a Lazy Loading cache invalidation strategy?
Pros:
- Only requested data is cached; cache isn’t filled with unused data
Cons:
- Cache miss penalty results in 3 round trips
- Stale data - data can be updated in db and outdated in cache