Cost Optimization - Database Flashcards
1
Q
RDS - Pricing points
A
- Instance type and size
- Database storage
- Data transfer out between AZs and between regions
- Backup storage
2
Q
RDS - Instance types
A
- General purpose: good balance between memory and network resources
- Burstable performance: offer a baseline level of CPU with the ability to surpass that baseline
- Memory optimized: designed for memory-intensive database workload
3
Q
RDS - Storage options
A
- General purpose SSD: default choice that offers balance for many uses cases. Provides a baseline of 3 IOPS / GiB
- Provisioned IOPS SSD: suitable for I/O-intensive database workloads. Can provision up to 256,000 IOPS
- Magnetic: cheapest storage, not recommended for new deployments
4
Q
RDS - Instance payment options
A
- On-demand: pay as you go, no upfront payments
- Reserved instances: 1 or 3 year commitment. Up to 69% savings
5
Q
RDS - Read replicas
A
- Offer asynchronous replication. It’s highly scalable
- Used for read scaling. Can be within the same or different AZ / Region
- Can be manually promoted to a standalone database instance, or a Multi-AZ instance
- When promoted to a Multi-AZ instance, it will be independent of whether the source database is a Multi-AZ instance too. It’s like an active-pasive deployment
6
Q
RDS - Multi-AZ deployments
A
- Offer synchronous replication. It’s highly durable
- Primary instance is only active
- There’s automatic failover to standby when a problem is detected
- Automatic backups are taken from standby
7
Q
DynamoDB - On-demand mode request units
A
- Write request unit (WRU): equivalent to one write of a 1KB item
- Read request units (RRU): represents one strongly consistent read request, or one-half eventually consistent read request for a 4KB item. Transactional read requests require two RRUs to read a 4KB item
- The number of reads for transactional read requests depends on the consistency model chosen (strong or eventual)
8
Q
DynamoDB - Provisioned mode capacity units
A
- Write capacity unit (WCU): equivalent to one write per second of a 1KB item
- Read capacity units (RCU): represents one strongly consistent read per second, or up to two eventually consistent reads per second for a 4KB item. Transactional read requests require two RCUs to do one read per second for a 4KB item
- The number of reads for transactional read requests depends on the consistency model chosen (strong or eventual)
9
Q
DynamoDB - Pricing points
A
- Always charged for data stored at a per GB-month rate
- Can purchase RCUs and WCUs with a 1 or 2 year commitment at a reduced rate
- On provisioned mode, if more reads and / or writes are needed:
- DynamoDB will throttle your connections until it drops reads and writes, or
- You can purchase more capacity units to be allocated
- Have additional costs:
- Global secondary indexes and Global DynamoDB tables will need their own capacity units
- DynamoDB backups