Q59 — AWS SAP-C02 Ch.1

Question 59 of 75 | ← Chapter 1

Q134. A retail company is operating its ecommerce application on AWS.The application runs on Amazon EC2 instances behind an Application Load Balancer (ALB).The company uses an Amazon RDS DB instance as the database backend. Amazon CloudFront is configured with one origin that points to the ALB.Static content is cached. Amazon Route 53 is used to host all public zones.After an update of the application, the ALB occasionally returns a 502 status code(Bad Gateway) error. The root cause is malformed HTTP headers that are returned to the ALB.The webpage returns successfully when a solutions architect reloads the webpage immediately after the error occurs.While the company is working on the problem, the solutions architect needs to provide a custom error page instead of the standard ALB error page to visitors.Which combination of steps will meet this requirement with the LEAST amount of operational overhead? (Select TWO.)

Correct Answer: A. Create an Amazon S3 bucket. Configure the S3 bucket to host a static webpage. Upload the custom error pages to Amazon S3, E. Add a custom error response by configuring a CloudFront custom error page. Modify DNS records to point to a publicly accessible web page

Explanation

"Save your custom error pages in a location that is accessible to CloudFront. We recommend that you store them in an Amazon S3 bucket, and that you don’t store them in the same place as the rest of your website or application’s content. If you store the custom error pages on the same origin as your website or application, and the origin starts to return 5xx errors, CloudFront can’t get the custom error pages because the origin server is unavailable." https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/GeneratingCustomErrorResponses.html