
Ultimate access to all questions.
A company's application relies on a MySQL-compatible Amazon Aurora Multi-AZ DB cluster, which includes a cross-Region read replica established for disaster recovery. In the event of a primary database failure, a DevOps engineer needs to automate the process of promoting the read replica to become the new primary database instance. What solution should be implemented to achieve this automation?
A
Set up a latency-based Amazon Route 53 CNAME with health checks that directs to both the primary and replica endpoints. Utilize an Amazon SNS topic subscribed to Amazon RDS failure notifications from AWS CloudTrail to trigger an AWS Lambda function that will elevate the replica instance to the primary role.
B
Establish an Aurora custom endpoint that targets the primary database instance. Configure the application to utilize this endpoint. Leverage AWS CloudTrail to execute an AWS Lambda function that promotes the replica instance and updates the custom endpoint to reflect the newly promoted instance.
C
Develop an AWS Lambda function that alters the application's AWS CloudFormation template to promote the replica, applies the template to update the stack, and directs the application to the newly promoted instance. Establish an Amazon CloudWatch alarm to activate this Lambda function following a failure event.
D
Archive the Aurora endpoint in AWS Systems Manager Parameter Store. Generate an Amazon EventBridge event that identifies database failures and executes an AWS Lambda function to promote the replica instance, updating the endpoint URL in AWS Systems Manager Parameter Store. Program the application to refresh the endpoint from Parameter Store upon detecting a database connection failure.