0
0
GCPcloud~20 mins

Request-based auto scaling in GCP - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Request-based Auto Scaling Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
service_behavior
intermediate
2:00remaining
How does request-based auto scaling respond to traffic spikes?

In Google Cloud Run, when request-based auto scaling is enabled, what happens if your service suddenly receives a large number of requests?

ACloud Run rejects new requests until the traffic decreases to the previous level.
BCloud Run instantly creates new instances to handle all incoming requests without delay.
CCloud Run queues all requests until the existing instances finish processing, then creates new instances.
DCloud Run gradually adds new instances based on the number of concurrent requests per instance until the traffic is handled efficiently.
Attempts:
2 left
💡 Hint

Think about how Cloud Run balances load and scales instances smoothly.

Configuration
intermediate
2:00remaining
Configuring max instances for request-based auto scaling

You want to limit the maximum number of instances your Cloud Run service can scale to during high traffic. Which configuration setting controls this limit?

ASetting the <code>min-instances</code> flag to zero in the Cloud Run service configuration.
BSetting the <code>max-instances</code> flag in the Cloud Run service deployment configuration.
CSetting the <code>concurrency</code> value to 1 in the Cloud Run service configuration.
DSetting the <code>timeout</code> value to the lowest possible number.
Attempts:
2 left
💡 Hint

Think about which setting limits the upper bound of instances.

Architecture
advanced
2:30remaining
Designing a Cloud Run service for efficient request-based auto scaling

You have a Cloud Run service that processes image uploads. To optimize cost and performance, which architecture choice best supports efficient request-based auto scaling?

ASet concurrency to 1 and allow max-instances to scale to 100, so each instance handles one request at a time but many instances can run.
BSet concurrency to 1 and max-instances to 1, so only one instance handles all requests sequentially.
CSet concurrency to a higher number like 80 and limit max-instances to a moderate number like 10, so each instance handles multiple requests concurrently.
DSet concurrency to 1000 and max-instances to 1, so one instance handles all requests concurrently.
Attempts:
2 left
💡 Hint

Think about balancing instance count and concurrency for cost and performance.

security
advanced
2:30remaining
Security considerations with request-based auto scaling in Cloud Run

When using request-based auto scaling in Cloud Run, what is a key security best practice to protect your service from sudden traffic spikes caused by malicious requests?

AUse Cloud Armor or similar tools to filter and block malicious traffic before it reaches Cloud Run.
BIncrease the request timeout to allow long-running requests to complete.
CSet max-instances to unlimited to handle any traffic volume without restrictions.
DDisable authentication to allow all requests to pass through quickly for scaling.
Attempts:
2 left
💡 Hint

Think about how to prevent bad traffic from causing resource waste.

Best Practice
expert
3:00remaining
Optimizing request-based auto scaling for cost and latency

You want to optimize your Cloud Run service to balance cost and latency during unpredictable traffic. Which combination of settings and practices achieves this best?

ASet concurrency moderate, max-instances moderate, and enable minimum instances to reduce cold starts while controlling cost.
BSet concurrency high, max-instances low, and disable minimum instances to save cost but accept cold starts.
CSet concurrency to 1, max-instances high, and enable minimum instances to keep some instances always warm.
DSet concurrency low, max-instances low, and disable minimum instances to minimize resource usage.
Attempts:
2 left
💡 Hint

Think about trade-offs between keeping instances warm and controlling max scale.