A company runs a core transactional retail application on AWS. The application database is deployed on Amazon RDS for PostgreSQL in a Multi-AZ configuration using a `io2` storage volume provisioned at IOPS. Database metric analysis shows that during normal operations ( days of the month), the workload is steady, consuming an average of write IOPS and read IOPS. During a -day monthly flash sale event, read queries scale dramatically, requiring up to read IOPS, while write IOPS remain steady at IOPS. The system must maintain high availability with automatic failover at all times. Which database design modification is the most cost-effective solution to handle this workload?
- Migrate the database to Amazon Aurora PostgreSQL. Deploy a Multi-AZ cluster consisting of one writer instance and one reader instance. Configure Aurora Auto Scaling for the reader instances to dynamically scale out up to five reader instances during the flash sale events, and scale back down to a single reader instance afterwards.Cevap
- BConvert the Amazon RDS for PostgreSQL database to a Single-AZ deployment using `gp3` storage with provisioned IOPS to minimize baseline costs. Deploy an Amazon RDS Read Replica in a different Availability Zone to handle the read query spikes during flash sales, and configure custom scripts to promote this replica to the primary instance in the event of a failure.
- CMigrate the relational database schema and data to Amazon DynamoDB. Configure the DynamoDB table with Provisioned Capacity Mode and enable Auto Scaling. Set the minimum Read Capacity Units (RCUs) to and the maximum to to automatically handle the flash sale spikes while keeping costs low during normal operations.
- DModify the existing Amazon RDS for PostgreSQL Multi-AZ deployment's storage type from `io2` to `gp3` and provision IOPS. Create an AWS Budgets alert to notify the operations team when costs exceed the baseline threshold, and manually scale the provisioned IOPS down to after each flash sale event ends.
Cevap
Migrate the database to Amazon Aurora PostgreSQL. Deploy a Multi-AZ cluster consisting of one writer instance and one reader instance. Configure Aurora Auto Scaling for the reader instances to dynamically scale out up to five reader instances during the flash sale events, and scale back down to a single reader instance afterwards.
Migrating the database to Amazon Aurora PostgreSQL with a Multi-AZ cluster consisting of one writer and one reader instance, and configuring Aurora Auto Scaling for the reader instances, is the most cost-effective solution. Since Aurora's storage architecture automatically scales performance and storage space without requiring provisioned IOPS, the company avoids the high cost of provisioned `io2` storage. Because the flash sale spikes are read-heavy, Aurora Auto Scaling can dynamically provision additional reader instances to handle the read IOPS and scale them down when the event ends, aligning instance capacity and cost with actual demand while maintaining full Multi-AZ high availability.
Adım Adım Çözüm
Anahtar Kavram
Cost-optimized database capacity planning leverages Aurora's decoupled storage and Auto Scaling read replicas to handle periodic read-heavy spikes, avoiding the high cost of provisioned database storage.