Google Professional Cloud Network Engineer Question 210
Single answerGoogle Cloud PlatformYou are designing a Google Cloud environment for a multi-tier application. The application requires a frontend web tier, a backend API tier, and a database tier. Each tier must be isolated while allowing necessary communication between tiers. You also need to ensure that the solution is scalable and maintains security best practices. Which configuration should you implement within your VPC?
- A
Create three separate VPCs, one for each tier, and use VPC Network Peering to enable communication between them.
- B
Create a single VPC and use subnetworks to separate each tier, applying firewall rules to control communication between them.
- C
Create three separate VPCs, one for each tier, and use Cloud VPN to connect them.
- D
Create a single VPC and use shared VPC configurations to isolate each tier at the project level.
Show answer and explanation
Correct answer: B
Explanation
The best practice for configuring VPCs for a multi-tier application is to use a single VPC with subnetworks to isolate each tier. This approach simplifies management, ensures scalability, and enables fine-grained control using firewall rules. Using separate VPCs with VPC Network Peering or Cloud VPN is unnecessarily complex for this scenario, while shared VPCs are intended for cross-project resource sharing rather than intra-application tier isolation.
- A. Incorrect.
This approach is overly complex and not necessary for isolating tiers within a single application. VPC Network Peering is typically used for connecting distinct networks, not for intra-application tier separation.
- B. Correct.
This is the best approach as it uses a single VPC with subnetworks to isolate tiers while maintaining simplicity and scalability. Firewall rules can be used to enforce security policies between tiers.
- C. Incorrect.
Using Cloud VPN for connecting application tiers within the same environment is inefficient and adds unnecessary overhead. This method is more suitable for hybrid or multi-cloud scenarios.
- D. Incorrect.
Shared VPC is designed for resource sharing across projects in an organization, not for isolating tiers of a single application within the same project.