nerdexam
Google

PROFESSIONAL-CLOUD-DEVELOPER · Question #321

You are the lead developer for a company that provides a financial risk calculation API. The API is built on Cloud Run and has a gRPC interface. You frequently develop optimizations to the risk…

The correct answer is C. Migrate the traffic to the new service by using a feature flag for registered customers. The key requirement is enabling new optimizations for select registered customers - not a percentage of random traffic. A traffic split (A) and blue/green (B) operate at the infrastructure level and route traffic randomly or wholesale, with no awareness of which customer is…

Application Deployment Strategies

Question

You are the lead developer for a company that provides a financial risk calculation API. The API is built on Cloud Run and has a gRPC interface. You frequently develop optimizations to the risk calculators. You want to enable these optimizations for select customers who registered to try out the optimizations prior to rolling out the optimization to all customers. Your CI/CD pipeline has built a new image and stored it in the Artifact Registry. Which rollout strategy should you use?

Options

  • AMigrate the traffic to the new service by setting Cloud Run's traffic split based on the percentage
  • BMigrate the traffic to the new service by using a blue/green deployment approach.
  • CMigrate the traffic to the new service by using a feature flag for registered customers.
  • DMigrate the traffic to the new service and enable session affinity for Cloud Run.

How the community answered

(60 responses)
  • A
    5% (3)
  • B
    12% (7)
  • C
    82% (49)
  • D
    2% (1)

Explanation

The key requirement is enabling new optimizations for select registered customers - not a percentage of random traffic. A traffic split (A) and blue/green (B) operate at the infrastructure level and route traffic randomly or wholesale, with no awareness of which customer is making the request. Session affinity (D) ensures a user sticks to the same instance but does not control which users get the new behavior. A feature flag (C) is the only mechanism that lets the application check whether the authenticated customer is in the registered cohort and then apply the optimization accordingly - giving precise, customer-aware control without any infrastructure change.

Topics

#Feature Flags#Deployment Strategies#Targeted Rollouts#Cloud Run

Community Discussion

No community discussion yet for this question.

Full PROFESSIONAL-CLOUD-DEVELOPER Practice