nerdexam
Google

PROFESSIONAL-CLOUD-DEVELOPER · Question #142

You are developing an ecommerce web application that uses App Engine standard environment and Memorystore for Redis. When a user logs into the app, the application caches the user's information…

The correct answer is B. You configured your Serverless VPC Access connector in a different region than your App Engine. Memorystore for Redis is a fully managed, private-only service - it has no public IP address and is only accessible from within the same VPC. App Engine standard environment runs in a Google-managed sandbox and cannot access VPC resources directly. A Serverless VPC Access…

Integrating Google Cloud Services

Question

You are developing an ecommerce web application that uses App Engine standard environment and Memorystore for Redis. When a user logs into the app, the application caches the user's information (e.g., session, name, address, preferences), which is stored for quick retrieval during checkout. While testing your application in a browser, you get a 502 Bad Gateway error. You have determined that the application is not connecting to Memorystore. What is the reason for this error?

Options

  • AYour Memorystore for Redis instance was deployed without a public IP address.
  • BYou configured your Serverless VPC Access connector in a different region than your App Engine
  • CThe firewall rule allowing a connection between App Engine and Memorystore was removed
  • DYou configured your application to use a Serverless VPC Access connector on a different subnet

How the community answered

(53 responses)
  • A
    15% (8)
  • B
    75% (40)
  • C
    6% (3)
  • D
    4% (2)

Explanation

Memorystore for Redis is a fully managed, private-only service - it has no public IP address and is only accessible from within the same VPC. App Engine standard environment runs in a Google-managed sandbox and cannot access VPC resources directly. A Serverless VPC Access connector bridges App Engine standard to the VPC, enabling it to reach Memorystore. Critically, the connector must be in the same region as the App Engine application. If the connector is in a different region than the App Engine app, the two cannot route traffic through it, resulting in a failed connection and the 502 Bad Gateway error. Option A is incorrect because Memorystore intentionally has no public IP - that is by design, not a misconfiguration. Option C (firewall rules) and D (subnet misconfiguration) are less likely root causes in this specific scenario, where the region mismatch is the canonical cause.

Topics

#App Engine#Memorystore#Serverless VPC Access#Networking

Community Discussion

No community discussion yet for this question.

Full PROFESSIONAL-CLOUD-DEVELOPER Practice