Google Cloud Professional Cloud Network Engineer — Question 14

You have deployed a new internal application that provides HTTP and TFTP services to on-premises hosts. You want to be able to distribute traffic across multiple
Compute Engine instances, but need to ensure that clients are sticky to a particular instance across both services.
Which session affinity should you choose?

Answer options

Correct answer: B

Explanation

The correct answer is B, 'Client IP', as it ensures that requests from the same client IP address are consistently directed to the same instance, which is essential for maintaining session continuity across both HTTP and TFTP services. The other options do not provide the necessary stickiness across both services; for instance, 'None' does not maintain any session affinity, and 'Client IP and protocol' or 'Client IP, port and protocol' would not be required since the primary aim is to stick to the client IP alone.