
Answer-first summary for fast verification
Answer: Modify the ALB target group configuration by enabling the stickiness attribute. Use an application-based cookie. Set the duration to the maximum application session length.
The issue described is a classic session persistence problem, where the application requires that all requests from a user during a session are sent to the same instance. The Application Load Balancer (ALB) supports session stickiness, which can be configured to ensure that requests from the same user are forwarded to the same target. This is achieved by enabling the stickiness attribute in the ALB target group configuration and using an application-based cookie. The duration should be set to the maximum application session length to ensure that the session persists for the required time. Option A suggests modifying the ALB listener configuration to enable group-level stickiness, which is not the correct approach for session persistence based on application cookies. Option B suggests replacing the ALB with a Network Load Balancer (NLB) and configuring TLS, which does not address the session persistence issue. Option D suggests removing the ALB and using Amazon Route 53 with a failover routing policy, which is not a solution for session persistence. Therefore, the correct action is to modify the ALB target group configuration by enabling the stickiness attribute and using an application-based cookie, as described in option C.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
A company has deployed a new web application on Amazon EC2 instances within private subnets across three Availability Zones, fronted by an Application Load Balancer (ALB). Security auditors mandate encryption for all connections. The company utilizes Amazon Route 53 for DNS and AWS Certificate Manager (ACM) for automated SSL/TLS certificate provisioning, with SSL/TLS termination occurring at the ALB.
During testing with a single EC2 instance, no issues were observed. However, after deploying to production, users report being able to log in but are unable to use the application, as each new web request forces a restart of the login process.
What steps should a network engineer take to resolve this issue?
A
Modify the ALB listener configuration. Edit the rule that forwards traffic to the target group. Change the rule to enable group-level stickiness. Set the duration to the maximum application session length.
B
Replace the ALB with a Network Load Balancer. Create a TLS listener. Create a new target group with the protocol type set to TLS Register the EC2 instances. Modify the target group configuration by enabling the stickiness attribute.
C
Modify the ALB target group configuration by enabling the stickiness attribute. Use an application-based cookie. Set the duration to the maximum application session length.
D
Remove the ALB. Create an Amazon Route 53 rule with a failover routing policy for the application name. Configure ACM to issue certificates for each EC2 instance.