Which solution meets these requirements?
Convert the existing database instance to a Multi-AZ deployment by modifying the database instance and specifying the Multi-AZ option.
Create a new RDS Multi-AZ deployment. Take a snapshot of the current RDS instance and restore the new Multi-AZ deployment with the snapshot.
Create a read-only replica of the PostgreSQL database in another Availability Zone. Use Amazon Route 53 weighted record sets to distribute requests across the databases.
Place the RDS for PostgreSQL database in an Amazon EC2 Auto Scaling group with a minimum group size of two. Use Amazon Route 53 weighted record sets to distribute requests across instances.
Explanations:
Converting the existing database instance to a Multi-AZ deployment will create a standby instance in another Availability Zone. This setup automatically handles failover in the event of an outage, thus minimizing database downtime without requiring any application code changes.
While creating a new Multi-AZ deployment from a snapshot of the current instance is a valid approach, it involves creating a new instance rather than modifying the existing one. This process would require updating the application configuration to point to the new instance, which does not meet the requirement of not changing application code.
Creating a read-only replica in another Availability Zone may improve availability for read operations, but it does not eliminate downtime for write operations. Additionally, this approach requires application code changes to direct write traffic appropriately, which violates the requirement of not requiring changes to the application code.
Placing the RDS database in an EC2 Auto Scaling group is not applicable, as RDS instances cannot be part of Auto Scaling groups. Furthermore, this option suggests using Route 53 for load balancing, which would not help in maintaining database availability and consistency across multiple instances for a single database.